結果

問題 No.264 じゃんけん
ユーザー OGNMOGNM
提出日時 2016-11-12 21:39:15
言語 Java21
(openjdk 21)
結果
AC  
実行時間 123 ms / 5,000 ms
コード長 507 bytes
コンパイル時間 3,204 ms
コンパイル使用メモリ 72,452 KB
実行使用メモリ 56,232 KB
最終ジャッジ日時 2023-08-17 03:58:16
合計ジャッジ時間 5,103 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 119 ms
56,016 KB
testcase_01 AC 121 ms
56,052 KB
testcase_02 AC 123 ms
55,560 KB
testcase_03 AC 119 ms
55,704 KB
testcase_04 AC 120 ms
54,608 KB
testcase_05 AC 120 ms
56,232 KB
testcase_06 AC 120 ms
56,164 KB
testcase_07 AC 120 ms
56,232 KB
testcase_08 AC 122 ms
56,148 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
public class Study_01 {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
        int n1 = sc.nextInt();
        int n2 = sc.nextInt();
        if(n1 == n2){
        	System.out.println("Drew");
        } else if((n1 == 0 && n2 == 1)||(n1==1 && n2 == 2) ||(n1==2 && n2==0)){
        	System.out.println("Won");        	
        } else if((n1 == 0 && n2 == 2)||(n1==1 && n2 == 0) ||(n1==2 && n2==1)){
        	System.out.println("Lost");
        }	
    }
}
0