結果
| 問題 | No.842 初詣 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-07-03 15:34:20 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 876 bytes |
| 記録 | |
| コンパイル時間 | 3,150 ms |
| コンパイル使用メモリ | 73,312 KB |
| 実行使用メモリ | 37,060 KB |
| 最終ジャッジ日時 | 2024-09-15 07:39:51 |
| 合計ジャッジ時間 | 5,095 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 11 WA * 10 |
ソースコード
package test.demo;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Yukicoder842 {
public static void main(String[] args) {
// TODO 自動生成されたメソッド・スタブ
BufferedReader bf=new BufferedReader(new InputStreamReader(System.in));
try {
String str =bf.readLine();
String[]str2=str.split(" ");
int a=Integer.parseInt(str2[0]);
int b=Integer.parseInt(str2[1]);
int c=Integer.parseInt(str2[2]);
int d=Integer.parseInt(str2[3]);
int e=Integer.parseInt(str2[4]);
int f=Integer.parseInt(str2[5]);
int g=Integer.parseInt(str2[6]);
if(a*500+b*100+c*50+d*10+e*5+f==g) {
System.out.println("YES");
}else {
System.out.println("NO");
}
} catch (IOException e) {
// TODO 自動生成された catch ブロック
e.printStackTrace();
}
}
}