Submission #122244


Source Code Expand

Copy
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class a {

	public static void main(String[] args) throws IOException {
		int sum=0;
		BufferedReader r =
	            new BufferedReader(new InputStreamReader(System.in), 1);
		String s = r.readLine();
		int a = Integer.parseInt(s);

		for(int i=1;i<=a;i++){
			sum += i*10000*(1.0/a);
		}
		System.out.println(sum);
	}

}

Submission Info

Submission Time
Task A - AtCoder社の給料
User switch
Language Java (OpenJDK 1.7.0)
Score 0
Code Size 443 Byte
Status CE

Compile Error

./Main.java:5: error: class a is public, should be declared in a file named a.java
public class a {
       ^
1 error