Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- .@@@@@@@@ @@@ @@ @@
- ,@@@@@@ @@ .@@@ @@ @@@ @@@%@@@@. @@@ @@ @@ @@@@/ @@@
- /& @@@@ @@@ *@@@ @@@# @@@&@@@ @@@@@@@#&@@ @@@%&, @@ @@@@ @@@@ @@@&
- @@@ .@@@ /@%@ @@@ @@@@ @@& .@@@ @@&&&@ @@ @@@@ (@@@@ @@@@
- %@@@@@@& /&&& %@& @&@ @& @&@& &&@#%@%. &@@ &@&# %@@@@@@
- @@@@@ /@&%(%&@@@&@ @&& ,@@ @@&&@@&@@@ &@@ /@@&/ @@, @@@/ %@@@(
- @@@. *@@@@#, @@@ @@@ ,@@ @@@. @@@ @@@@@@@ %@@/ @@@@@@%
- @@@ *@@% @@@ @@@@@@# @@@@@@@@@@ @@@ ,@@@@ @@& .@@@ @@@@
- &@@, @@% @@ @@@ @@ @@@
- &*
- */
- #include <bits/stdc++.h>
- // #include "phoenix.h"
- #define ceil(n, m) (((n) / (m)) + ((n)%(m) ? 1 : 0))
- #define endl "\n"
- #define NumOfDig(n) log10(n) + 1
- #define MOD 1000000007
- #define INF 2000000000
- #define Time cerr << "Time Taken: " << (float)clock() / CLOCKS_PER_SEC << " Secs" << "\n";
- #define EPS 1e-9
- #define PI1 acos(-1)
- #define PI2 3.141592653
- #define all(s) s.begin(), s.end()
- #define rall(s) s.rbegin(), s.rend()
- // #define getline(s) getline(cin >> ws, s)
- using namespace std;
- typedef long long ll;
- typedef unsigned long long ull;
- /**
- * @author MiinaMagdy 😌🙋♂️
- * @remark Time limit - memory limit (efficiency)
- * @remark (OVERFLOW) long long
- * @remark freopen() file
- * @remark (CORNER) test case
- * @remark division by (ZERO) || Out of array's (RANGE)
- * @remark use logarithm if you want to compare two products
- */
- void phoenix()
- {
- ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
- #ifndef ONLINE_JUDGE
- freopen("input.txt", "r", stdin), freopen("output.txt", "w", stdout);
- #endif
- Time
- }
- int main(void)
- {
- phoenix();
- ll testcases = 1;
- // cin >> testcases;
- while (testcases--)
- {
- string s;
- cin >> s;
- map<char, int> freq;
- for (auto & i : s) freq[i]++;
- int cnt = 0;
- for (auto & i : freq) {
- cnt += (i.second%2);
- }
- cout << max(0, cnt - 1) << endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement