結果

問題 No.438 Cwwプログラミング入門
ユーザー nebukuro09nebukuro09
提出日時 2016-10-29 00:16:41
言語 PyPy2
(7.3.15)
結果
WA  
実行時間 -
コード長 602 bytes
コンパイル時間 714 ms
コンパイル使用メモリ 77,064 KB
実行使用メモリ 78,248 KB
最終ジャッジ日時 2024-05-03 18:49:52
合計ジャッジ時間 47,057 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 643 ms
77,852 KB
testcase_03 AC 628 ms
77,952 KB
testcase_04 AC 628 ms
78,116 KB
testcase_05 AC 629 ms
78,120 KB
testcase_06 AC 620 ms
77,952 KB
testcase_07 AC 618 ms
77,692 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 AC 617 ms
77,952 KB
testcase_14 WA -
testcase_15 AC 634 ms
77,868 KB
testcase_16 WA -
testcase_17 WA -
testcase_18 AC 627 ms
77,356 KB
testcase_19 AC 618 ms
77,628 KB
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 624 ms
77,824 KB
testcase_25 WA -
testcase_26 WA -
testcase_27 AC 630 ms
77,436 KB
testcase_28 WA -
testcase_29 WA -
testcase_30 AC 627 ms
77,824 KB
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
testcase_34 WA -
testcase_35 WA -
testcase_36 WA -
testcase_37 WA -
testcase_38 AC 610 ms
77,568 KB
testcase_39 WA -
testcase_40 AC 616 ms
77,952 KB
testcase_41 WA -
testcase_42 WA -
testcase_43 AC 491 ms
77,440 KB
testcase_44 WA -
testcase_45 WA -
testcase_46 WA -
testcase_47 WA -
testcase_48 WA -
testcase_49 WA -
testcase_50 AC 615 ms
77,592 KB
testcase_51 AC 602 ms
77,692 KB
testcase_52 WA -
testcase_53 WA -
testcase_54 AC 605 ms
77,596 KB
testcase_55 WA -
testcase_56 WA -
testcase_57 WA -
testcase_58 AC 592 ms
77,480 KB
testcase_59 WA -
testcase_60 WA -
testcase_61 WA -
testcase_62 AC 597 ms
77,352 KB
testcase_63 WA -
testcase_64 WA -
testcase_65 AC 596 ms
77,844 KB
testcase_66 WA -
testcase_67 AC 617 ms
77,568 KB
testcase_68 WA -
testcase_69 WA -
testcase_70 WA -
testcase_71 WA -
testcase_72 WA -
testcase_73 WA -
testcase_74 WA -
testcase_75 WA -
testcase_76 WA -
testcase_77 WA -
testcase_78 AC 595 ms
77,860 KB
testcase_79 AC 606 ms
77,504 KB
testcase_80 AC 589 ms
77,844 KB
testcase_81 AC 600 ms
77,568 KB
testcase_82 AC 602 ms
77,440 KB
testcase_83 AC 598 ms
77,608 KB
testcase_84 AC 594 ms
77,476 KB
testcase_85 AC 617 ms
77,696 KB
testcase_86 AC 601 ms
77,628 KB
testcase_87 AC 609 ms
77,696 KB
testcase_88 WA -
testcase_89 WA -
testcase_90 AC 515 ms
77,584 KB
testcase_91 WA -
testcase_92 AC 553 ms
78,120 KB
testcase_93 WA -
testcase_94 AC 157 ms
76,808 KB
testcase_95 WA -
testcase_96 AC 629 ms
77,384 KB
testcase_97 WA -
testcase_98 AC 595 ms
77,828 KB
testcase_99 AC 609 ms
77,472 KB
testcase_100 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

x, y, z = map(int, raw_input().split())

def print_ans(a, b, w):
    a_op = 'C' if a > 0 else 'W'
    b_op = 'C' if b > 0 else 'W'
    if a> 0:
        print 'c' + (('c'+a_op)*(abs(a)-1) + ('w'+b_op)*abs(b))*w
    else:
        print 'w' + (('w'+b_op)*(abs(b)-1) + ('c'+a_op)*abs(a))*w

for a in xrange(-5000, 5000):
    for b in xrange(-5000+abs(a), 5000-abs(a)):
        c = a*x+b*y
        if c > 0 and z % c == 0:
            if a != 0 and b != 0:
                if 2*(abs(a)+abs(b))*(z/c)-1 <= 9970:
                    print_ans(a, b, z/c)
                    exit()
print 'mourennaihasimasenn'
0