結果

問題 No.191 供託金
ユーザー kou6839kou6839
提出日時 2015-04-26 22:03:25
言語 Java21
(openjdk 21)
結果
AC  
実行時間 135 ms / 5,000 ms
コード長 441 bytes
コンパイル時間 1,914 ms
コンパイル使用メモリ 71,120 KB
実行使用メモリ 56,488 KB
最終ジャッジ日時 2023-08-10 13:50:21
合計ジャッジ時間 6,313 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 119 ms
53,976 KB
testcase_01 AC 120 ms
56,256 KB
testcase_02 AC 118 ms
55,668 KB
testcase_03 AC 118 ms
55,452 KB
testcase_04 AC 129 ms
55,556 KB
testcase_05 AC 130 ms
56,300 KB
testcase_06 AC 127 ms
55,992 KB
testcase_07 AC 131 ms
55,872 KB
testcase_08 AC 122 ms
55,652 KB
testcase_09 AC 122 ms
56,248 KB
testcase_10 AC 130 ms
55,948 KB
testcase_11 AC 127 ms
55,984 KB
testcase_12 AC 120 ms
55,988 KB
testcase_13 AC 129 ms
56,012 KB
testcase_14 AC 129 ms
55,768 KB
testcase_15 AC 128 ms
55,564 KB
testcase_16 AC 126 ms
55,728 KB
testcase_17 AC 128 ms
56,132 KB
testcase_18 AC 121 ms
56,068 KB
testcase_19 AC 128 ms
55,916 KB
testcase_20 AC 125 ms
56,052 KB
testcase_21 AC 128 ms
55,960 KB
testcase_22 AC 135 ms
56,016 KB
testcase_23 AC 128 ms
56,080 KB
testcase_24 AC 128 ms
56,488 KB
testcase_25 AC 120 ms
55,656 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
	public static void main(String[] args){
		// TODO 自動生成されたメソッド・スタブ
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		double sum=0;
		int[] pol = new int[n];
		for(int i=0;i<n;i++){
			int a = sc.nextInt();
			sum+=a;
			pol[i]=a;
		}
		sum/=10;
		int ans=0;
		for(int i=0;i<n;i++){
			if(pol[i]<=sum){
				ans+=30;
			}
		}
		System.out.println(ans);
	}
}
0