| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 56944 | 汪天一 | Bill | C++ | Accepted | 100 | 1 MS | 252 KB | 364 | 2022-08-03 17:08:10 |
#include<bits/stdc++.h> using namespace std; int n,x1=0,x2=0,x3=0; char a,b; int main(){ cin>>n; for(int i=1;i<=n;i++){ cin>>a>>b; if(a=='D') x1++; if(a=='G') x2++; if(a=='Z') x3++; if(b=='D') x1--; if(b=='G') x2--; if(b=='Z') x3--; } cout<<"D"<<" "<<x1<<endl; cout<<"G"<<" "<<x2<<endl; cout<<"Z"<<" "<<x3<<endl; return 0; }