-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathC282A.java
More file actions
37 lines (28 loc) · 710 Bytes
/
Copy pathC282A.java
File metadata and controls
37 lines (28 loc) · 710 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
/**
* */
public class C282A {
/**
* @param args
*/
public static void main(String[] args) {
/**
Solution solution=new Solution(); */
BufferedReader reader =new BufferedReader(
new InputStreamReader(System.in)); // STDIN
try {
int nValue=0;
int nStatements=Integer.valueOf(reader.readLine().trim());
for(int i=0;i!=nStatements;i++){
String s=reader.readLine().trim();
nValue+=(s.contains("+"))?1:-1;
}
System.out.println(nValue);
reader.close();
} catch (IOException e) {
e.printStackTrace();
}
}
}