結果
| 問題 | No.79 過小評価ダメ・ゼッタイ |
| コンテスト | |
| ユーザー |
kou6839
|
| 提出日時 | 2014-11-30 23:51:38 |
| 言語 | Java (openjdk 25.0.2) |
| 結果 |
AC
|
| 実行時間 | 311 ms / 5,000 ms |
| コード長 | 532 bytes |
| 記録 | |
| コンパイル時間 | 1,558 ms |
| コンパイル使用メモリ | 84,204 KB |
| 実行使用メモリ | 56,324 KB |
| 最終ジャッジ日時 | 2026-03-12 23:19:19 |
| 合計ジャッジ時間 | 6,174 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 22 |
ソースコード
import java.math.BigInteger;
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int[] ans= new int[7];
for(int i=0;i<n;i++){
int t= sc.nextInt();
ans[t]++;
}
int anss=0;
int max=0;
for(int i=1;i<=6;i++){
if(ans[i]>=max) {
anss=i;
max=ans[i];
}
}
System.out.println(anss);
}
}
kou6839