Run ID | 作者 | 问题 | 语言 | 测评结果 | 分数 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|---|
331263 | 胡珂 | 【C5-4】石头剪子布 | C++ | 解答错误 | 0 | 2 MS | 252 KB | 662 | 2025-07-11 17:25:36 |
#include <bits/stdc++.h> using namespace std; int main() { string a1,a2; int n; cin >> n; for(int i=1;i<=n;i++){ cin>>a1>>a2; if(a1=="Rock"&&a2=="Scissors") cout <<"Player1"<<endl; if(a1=="Scissors"&&a2=="paper") cout <<"Player1"<<endl; if(a1=="paper"&&a2=="Rock") cout <<"Player1"<<endl; if(a1=="Rock"&&a2=="Rock") cout <<"Tie"<<endl; if(a1=="Scissors"&&a2=="Scissors") cout <<"Tie"<<endl; if(a1=="paper"&&a1=="paper") cout <<"Tie"<<endl; if(a2=="Rock"&&a1=="Scissors") cout <<"Player2"<<endl; if(a2=="Scissors"&&a1=="paper") cout <<"Player2"<<endl; if(a2=="paper"&&a1=="Rock") cout <<"Player2"<<endl; } return 0; }