Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- using namespace std;
- unsigned int a, b, c[100000], d[1000], w;
- int main ()
- {
- std::ios::sync_with_stdio(0);
- cin>>a>>b;
- for (int i=0; i<b; i++)
- {
- cin>>c[i];
- for (int k=0; k<a; k++)
- {
- if(c[i]==a-k) d[k]++;
- else cout<<"";
- }
- }
- for (int k=0; k<a; k++)
- {
- if (d[k]%2!=0)
- {
- w++;
- }
- else cout<<"";
- }
- cout<<w;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement