| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 56838 | 董承诺 | 排队买票 | C++ | Wrong Answer | 0 | 0 MS | 248 KB | 230 | 2022-08-03 15:12:14 |
#include<bits/stdc++.h> using namespace std; int a,c; string b; int main(){ cin>>a; for(int i=1;i<=a;i++){ cin>>b[i]; } for(int i=1;i<=a-1;i++){ if(b[i]!=b[i+1]) c++; else c+=0; } cout<<c+1; return 0; }