結果
問題 | No.355 数当てゲーム(2) |
ユーザー | AreTrash |
提出日時 | 2016-09-05 10:11:13 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 1,077 bytes |
コンパイル時間 | 2,498 ms |
コンパイル使用メモリ | 103,120 KB |
実行使用メモリ | 44,000 KB |
平均クエリ数 | 11.69 |
最終ジャッジ日時 | 2023-09-23 11:29:57 |
合計ジャッジ時間 | 14,407 ms |
ジャッジサーバーID (参考情報) |
judge12 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | RE | - |
testcase_01 | RE | - |
testcase_02 | AC | 96 ms
42,276 KB |
testcase_03 | RE | - |
testcase_04 | RE | - |
testcase_05 | RE | - |
testcase_06 | RE | - |
testcase_07 | AC | 97 ms
42,028 KB |
testcase_08 | RE | - |
testcase_09 | RE | - |
testcase_10 | AC | 96 ms
40,336 KB |
testcase_11 | AC | 97 ms
40,468 KB |
testcase_12 | RE | - |
testcase_13 | RE | - |
testcase_14 | RE | - |
testcase_15 | AC | 92 ms
41,768 KB |
testcase_16 | AC | 96 ms
40,044 KB |
testcase_17 | AC | 92 ms
40,116 KB |
testcase_18 | RE | - |
testcase_19 | RE | - |
testcase_20 | AC | 97 ms
42,288 KB |
testcase_21 | RE | - |
testcase_22 | RE | - |
testcase_23 | AC | 96 ms
40,320 KB |
testcase_24 | RE | - |
testcase_25 | AC | 104 ms
42,220 KB |
testcase_26 | AC | 103 ms
41,928 KB |
testcase_27 | RE | - |
testcase_28 | RE | - |
testcase_29 | RE | - |
testcase_30 | AC | 92 ms
40,316 KB |
testcase_31 | AC | 94 ms
41,640 KB |
testcase_32 | RE | - |
testcase_33 | AC | 91 ms
39,664 KB |
testcase_34 | RE | - |
testcase_35 | AC | 96 ms
44,000 KB |
testcase_36 | AC | 97 ms
42,420 KB |
testcase_37 | AC | 90 ms
41,696 KB |
testcase_38 | RE | - |
testcase_39 | AC | 101 ms
42,248 KB |
testcase_40 | AC | 99 ms
39,576 KB |
testcase_41 | RE | - |
testcase_42 | RE | - |
testcase_43 | RE | - |
testcase_44 | RE | - |
testcase_45 | RE | - |
testcase_46 | RE | - |
testcase_47 | RE | - |
testcase_48 | AC | 94 ms
41,612 KB |
testcase_49 | RE | - |
testcase_50 | AC | 95 ms
42,304 KB |
testcase_51 | RE | - |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System; using System.Linq; namespace No355{ public class Program{ public static void Main(string[] args){ Func<string, int[]> output = s =>{ if(s.Distinct().Count() != s.Length) return new [] {-1, -1}; Console.WriteLine(string.Join(" ", s.ToCharArray())); return Array.ConvertAll(Console.ReadLine().Split(' '), int.Parse); }; int[] res; var random = new Random(); while(true){ var i = random.Next(10000); var x = output(i.ToString()); if(x[0] == 4) return; if(x[0] == 0 && x[1] == 0){ res = i.ToString().Select(c => c - '0').ToArray(); break; } } for(var i = 0; i < 4; i++){ for(var j = 0; j < 10; j++){ res[i] = j; var x = output(string.Join("", res)); if(x[0] == i + 1) break; } } } } }