#include<iostream> #include<cstring> #define debug(x) cout<<">"<<x<<endl; using namespace std; int main() { int n,x; string s; while(cin>>n) { x=0; while(n--) { cin>>s; if(s=="X++" || s=="++X") x++; else if(s=="X--" || s=="--X") x--; } cout<<x<<endl; } return 0; }
Saturday, May 21, 2016
CF 282A
Labels:
Codeforces
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Thank you for commenting. Please wait for response :)