Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <bits/stdc++.h>
- #define uns unsigned
- #define ll long long
- const char newline('\n');
- using namespace std;
- ///**************************
- int n;
- string s;
- int nrn, nrz;
- int main()
- {
- cin >> n >> s;
- for (int i = 0; s[i]; i++)
- {
- if (s[i] == 'n')
- nrn++;
- else if (s[i] == 'z')
- nrz++;
- }
- while (nrn)
- {
- cout << 1 << ' ';
- nrn--;
- }
- while (nrz)
- {
- cout << 0 << ' ';
- nrz--;
- }
- return EXIT_SUCCESS;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement