diff --git a/525A Vitaliy and Pie/525A.cpp b/525A Vitaliy and Pie/525A.cpp new file mode 100644 index 0000000..068c9d9 --- /dev/null +++ b/525A Vitaliy and Pie/525A.cpp @@ -0,0 +1,42 @@ +#include +using namespace std; +using ll = long long; + +void solve() +{ + int n; + cin>>n; + string s; + cin>>s; + unordered_mapm; + int ct=0; + for(int i=0; i='a' && s[i]<='z') + { + m[s[i]]++; + } + else + { + char c; + c=tolower(s[i]); + if(m[c]>0) + { + m[c]--; + } + else ct++; + } + } + cout<> TC; + //cin.ignore(); + while (TC--) solve(); +} \ No newline at end of file