Skip to content

Commit c1ced16

Browse files
committed
study 😢
1 parent c9c2346 commit c1ced16

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import java.io.*;
2+
class Test3{
3+
public static void main(String args[]){
4+
int max = 100000000;
5+
int sum = 0;
6+
BufferedReader in = new BufferedReader(new FileReader("./sample.txt"));
7+
String s;
8+
while((s = in.readLine()) != null){
9+
sum += Integer.parseInt(s);
10+
}
11+
int result = (max)*(max+1)/2-sum;
12+
System.out.println(result);
13+
14+
in.close();
15+
}
16+
}

0 commit comments

Comments
 (0)