結果
| 問題 | 
                            No.191 供託金
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2016-01-10 15:22:00 | 
| 言語 | Java  (openjdk 23)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 138 ms / 5,000 ms | 
| コード長 | 429 bytes | 
| コンパイル時間 | 3,188 ms | 
| コンパイル使用メモリ | 73,876 KB | 
| 実行使用メモリ | 41,464 KB | 
| 最終ジャッジ日時 | 2024-11-16 21:59:01 | 
| 合計ジャッジ時間 | 7,138 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge5 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 23 | 
ソースコード
import java.util.Scanner;
public class No0191 {
	final static int DEPOSIT = 30;
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int[] C = new int[N];
		int vote = 0;
		int sum = 0;
		
		for(int i = 0; i < N; i++){
			C[i] = sc.nextInt();
			vote += C[i];
		}
		
		for(int c : C){
			if (c <= (vote / 10)){
				sum += DEPOSIT;
			}
		}
		System.out.println(sum);
		
	}
}