結果
| 問題 |
No.933 おまわりさんこいつです
|
| コンテスト | |
| ユーザー |
watarimaycry2
|
| 提出日時 | 2019-12-03 23:59:13 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 971 bytes |
| コンパイル時間 | 2,546 ms |
| コンパイル使用メモリ | 74,584 KB |
| 実行使用メモリ | 53,212 KB |
| 最終ジャッジ日時 | 2024-11-28 00:57:32 |
| 合計ジャッジ時間 | 10,456 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 22 WA * 3 |
ソースコード
import java.util.*;
public class Main {
static Scanner sc = new Scanner(System.in);
static void myout(Object t){System.out.println(t);}
static String getStr(){return sc.next();}
static int getInt(){return sc.nextInt();}
static Long getLong(){return sc.nextLong();}
static boolean isNext(){return sc.hasNext();}
public static void main(String[] args){
int N = getInt();
long[] list = new long[N];
long output = 1;
for(int i = 0; i < N; i++){
long p = getLong() % 9;
if(p == 0){
p = 9;
}
list[i] = p;
}
for(int i = 0; i < N; i++){
output = (output * list[i]) % 9;
if(output == 0){
output = 9;
}
}
myout(output);
}
//便利メソッド追加枠ここから
//便利メソッド追加枠ここまで
}
watarimaycry2