結果
問題 | No.438 Cwwプログラミング入門 |
ユーザー | nebukuro09 |
提出日時 | 2016-10-28 23:40:26 |
言語 | Python2 (2.7.18) |
結果 |
WA
|
実行時間 | - |
コード長 | 512 bytes |
コンパイル時間 | 141 ms |
コンパイル使用メモリ | 7,040 KB |
実行使用メモリ | 107,532 KB |
最終ジャッジ日時 | 2024-05-03 17:27:41 |
合計ジャッジ時間 | 9,150 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 10 ms
13,752 KB |
testcase_01 | WA | - |
testcase_02 | AC | 48 ms
35,584 KB |
testcase_03 | AC | 44 ms
35,840 KB |
testcase_04 | AC | 46 ms
35,820 KB |
testcase_05 | AC | 50 ms
36,080 KB |
testcase_06 | AC | 44 ms
35,840 KB |
testcase_07 | AC | 44 ms
37,504 KB |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | AC | 45 ms
34,816 KB |
testcase_14 | WA | - |
testcase_15 | AC | 43 ms
35,328 KB |
testcase_16 | WA | - |
testcase_17 | WA | - |
testcase_18 | AC | 45 ms
34,304 KB |
testcase_19 | AC | 45 ms
35,796 KB |
testcase_20 | WA | - |
testcase_21 | WA | - |
testcase_22 | WA | - |
testcase_23 | WA | - |
testcase_24 | AC | 43 ms
35,200 KB |
testcase_25 | WA | - |
testcase_26 | WA | - |
testcase_27 | AC | 43 ms
35,200 KB |
testcase_28 | AC | 10 ms
6,940 KB |
testcase_29 | AC | 9 ms
6,944 KB |
testcase_30 | AC | 44 ms
35,712 KB |
testcase_31 | WA | - |
testcase_32 | WA | - |
testcase_33 | AC | 9 ms
6,944 KB |
testcase_34 | AC | 9 ms
6,940 KB |
testcase_35 | WA | - |
testcase_36 | AC | 9 ms
6,944 KB |
testcase_37 | WA | - |
testcase_38 | AC | 47 ms
35,328 KB |
testcase_39 | WA | - |
testcase_40 | AC | 46 ms
35,840 KB |
testcase_41 | WA | - |
testcase_42 | WA | - |
testcase_43 | AC | 18 ms
6,944 KB |
testcase_44 | WA | - |
testcase_45 | AC | 10 ms
6,944 KB |
testcase_46 | WA | - |
testcase_47 | WA | - |
testcase_48 | TLE | - |
testcase_49 | -- | - |
testcase_50 | -- | - |
testcase_51 | -- | - |
testcase_52 | -- | - |
testcase_53 | -- | - |
testcase_54 | -- | - |
testcase_55 | -- | - |
testcase_56 | -- | - |
testcase_57 | -- | - |
testcase_58 | -- | - |
testcase_59 | -- | - |
testcase_60 | -- | - |
testcase_61 | -- | - |
testcase_62 | -- | - |
testcase_63 | -- | - |
testcase_64 | -- | - |
testcase_65 | -- | - |
testcase_66 | -- | - |
testcase_67 | -- | - |
testcase_68 | -- | - |
testcase_69 | -- | - |
testcase_70 | -- | - |
testcase_71 | -- | - |
testcase_72 | -- | - |
testcase_73 | -- | - |
testcase_74 | -- | - |
testcase_75 | -- | - |
testcase_76 | -- | - |
testcase_77 | -- | - |
testcase_78 | -- | - |
testcase_79 | -- | - |
testcase_80 | -- | - |
testcase_81 | -- | - |
testcase_82 | -- | - |
testcase_83 | -- | - |
testcase_84 | -- | - |
testcase_85 | -- | - |
testcase_86 | -- | - |
testcase_87 | -- | - |
testcase_88 | -- | - |
testcase_89 | -- | - |
testcase_90 | -- | - |
testcase_91 | -- | - |
testcase_92 | -- | - |
testcase_93 | -- | - |
testcase_94 | -- | - |
testcase_95 | -- | - |
testcase_96 | -- | - |
testcase_97 | -- | - |
testcase_98 | -- | - |
testcase_99 | -- | - |
testcase_100 | -- | - |
ソースコード
x, y, z = map(int, raw_input().split()) visited = set() d = [(x, 'cC'), (y, 'wC'), (-x, 'cW'), (-y, 'wW')] stack = [(x, 'c'), (y, 'w')] while len(stack) > 0: num, code = stack.pop() #print num if num in visited or num < 0: continue if num == z: print code exit() visited.add(num) if len(code) >= 9999: continue for nn, nc in d: if num+nn not in visited and num+nn >= 0: stack.append((num+nn, code+nc)) print 'mourennaihasimasenn'