結果

問題 No.304 鍵(1)
ユーザー ルッツファンルッツファン
提出日時 2015-11-27 22:41:32
言語 Java21
(openjdk 21)
結果
AC  
実行時間 190 ms / 2,000 ms
コード長 975 bytes
コンパイル時間 4,354 ms
コンパイル使用メモリ 72,108 KB
実行使用メモリ 68,684 KB
平均クエリ数 310.00
最終ジャッジ日時 2023-09-23 21:59:48
合計ジャッジ時間 5,700 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 62 ms
65,372 KB
testcase_01 AC 87 ms
65,868 KB
testcase_02 AC 190 ms
68,408 KB
testcase_03 AC 87 ms
66,072 KB
testcase_04 AC 144 ms
68,684 KB
testcase_05 AC 83 ms
66,196 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package yukicoder;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class yukicoder01 {
	public static void main(String[] args){
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String tes = null;
		
		System.out.println("000");
		
		
		try {
			tes = br.readLine();
		} catch (IOException e) {
			// TODO 自動生成された catch ブロック
			e.printStackTrace();
		}
		
		if(tes.equals("unlocked")){
			System.exit(0);
		}
		
		int i = 0;
		String tmp;
		
		while(true){
			
			if(i < 10){
				tmp = "00"+String.valueOf(i);
			}else if(i < 100){
				tmp = "0"+String.valueOf(i);
			}else{
				tmp = String.valueOf(i);
			}
			
			System.out.println(tmp);
			
			try {
				tes = br.readLine();
			} catch (IOException e) {
				// TODO 自動生成された catch ブロック
				e.printStackTrace();
			}
			if(tes.equals("unlocked")){
				System.exit(0);
			}
			
			i++;
		}
		
	}

}
0