#include <bits/stdc++.h>
#define LLI long long int
#define LD long double
#define PB push_back
#define MP make_pair
#define FORi(i, a, b) for(int i = a; i < b ; ++i)
#define FORd(i, a, b) for(int i = a; i > b ; --i)
using namespace std;
const int mod = 1e9 + 7;
struct comp{
bool operator()(pair<int,char>& a, pair<int,char>& b){
if (a.first == b.first){
if (a.second == '+')
return 1;
else
return a==b;
}
return a.first < b.first;
}
};
int main() {
int n, ans=1;
cin >> n;
vector<pair<int,char> > v(n);
FORi(i,0,n){
cin >> v[i].first >> v[i].second;
}
sort(v.begin(), v.end(), comp());
bool is_neg = 0;
FORi(i,0,n){
if (is_neg && v[i].second == '+'){
ans++;
break;
}
if (!is_neg && v[i].second == '-'){
is_neg = 1;
}
}
cout << ans;
return 0;
}
I2luY2x1ZGUgPGJpdHMvc3RkYysrLmg+CiAKI2RlZmluZSBMTEkgbG9uZyBsb25nIGludAojZGVmaW5lIExEIGxvbmcgZG91YmxlCiNkZWZpbmUgUEIgcHVzaF9iYWNrCiNkZWZpbmUgTVAgbWFrZV9wYWlyCiNkZWZpbmUgRk9SaShpLCBhLCBiKSBmb3IoaW50IGkgPSBhOyBpIDwgYiA7ICsraSkKI2RlZmluZSBGT1JkKGksIGEsIGIpIGZvcihpbnQgaSA9IGE7IGkgPiBiIDsgLS1pKQogCnVzaW5nIG5hbWVzcGFjZSBzdGQ7CiAKY29uc3QgaW50IG1vZCA9IDFlOSArIDc7CgpzdHJ1Y3QgY29tcHsKCWJvb2wgb3BlcmF0b3IoKShwYWlyPGludCxjaGFyPiYgYSwgcGFpcjxpbnQsY2hhcj4mIGIpewoJCWlmIChhLmZpcnN0ID09IGIuZmlyc3QpewoJCQlpZiAoYS5zZWNvbmQgPT0gJysnKQoJCQkJcmV0dXJuIDE7CgkJCWVsc2UKCQkJCXJldHVybiBhPT1iOwoJCX0KCQlyZXR1cm4gYS5maXJzdCA8IGIuZmlyc3Q7Cgl9CQp9OwoKaW50IG1haW4oKSB7CglpbnQgbiwgYW5zPTE7C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