結果

問題 No.191 供託金
ユーザー marumaru
提出日時 2016-03-23 01:53:26
言語 Java
(openjdk 23)
結果
AC  
実行時間 145 ms / 5,000 ms
コード長 461 bytes
コンパイル時間 4,025 ms
コンパイル使用メモリ 74,072 KB
実行使用メモリ 41,468 KB
最終ジャッジ日時 2024-11-16 22:03:39
合計ジャッジ時間 8,205 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class yukicoder_191 {
	public static void main(String[] args) {
		Scanner stdIn = new Scanner(System.in);
		
		int n = stdIn.nextInt();
		int[] c = new int[n];
		
		int sosu = 0;
		
		for (int i = 0; i < n; i++) {
			c[i] = stdIn.nextInt();
			sosu += c[i];
		}
		
		int yuko = sosu / 10;
		int ninzu = 0;
		
		for (int i = 0; i < n; i++) {
			if (c[i] <= yuko) {
				ninzu++;
			}
		}
		
		System.out.println(ninzu * 30);
	}
}
0