結果

問題 No.264 じゃんけん
ユーザー springspring
提出日時 2019-06-12 13:09:44
言語 Java21
(openjdk 21)
結果
AC  
実行時間 134 ms / 5,000 ms
コード長 400 bytes
コンパイル時間 2,454 ms
コンパイル使用メモリ 74,320 KB
実行使用メモリ 54,132 KB
最終ジャッジ日時 2024-04-18 10:30:58
合計ジャッジ時間 3,982 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 128 ms
53,984 KB
testcase_01 AC 127 ms
53,988 KB
testcase_02 AC 134 ms
54,132 KB
testcase_03 AC 125 ms
54,008 KB
testcase_04 AC 132 ms
54,084 KB
testcase_05 AC 132 ms
53,860 KB
testcase_06 AC 129 ms
54,064 KB
testcase_07 AC 128 ms
54,104 KB
testcase_08 AC 125 ms
54,028 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int my = sc.nextInt();
		int you = sc.nextInt();
		if(my==you){
			System.out.println("Drew");
		}else{
			int result = my-you;
			if(result == 2||result==-1){
				System.out.println("Won");
			}else{
				System.out.println("Lost");
			}
		}

	}// mainmethod

} // class
0