Run ID:84536
提交时间:2024-07-16 09:55:09
#include<bits/stdc++.h> using namespace std; int a[100]; int main() { int x=0,y=0,z=0,n=0,t; while(ture) { cin>>t; if(t==-1) { break; } n++; if(t==1) { x++; } else if(t==2) { y++; } else (t==3) { z++; } } cout<<"A="<<x<<endl; cout<<"B="<<y<<endl; cout<<"C="<<z<<endl; return 0; }