結果

問題 No.2109 Special Week
ユーザー ThetaTheta
提出日時 2022-10-31 11:16:43
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 21 ms / 2,000 ms
コード長 576 bytes
コンパイル時間 111 ms
コンパイル使用メモリ 10,808 KB
実行使用メモリ 9,200 KB
最終ジャッジ日時 2023-09-22 09:07:37
合計ジャッジ時間 2,860 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 21 ms
8,976 KB
testcase_01 AC 20 ms
9,164 KB
testcase_02 AC 19 ms
9,152 KB
testcase_03 AC 20 ms
9,112 KB
testcase_04 AC 20 ms
9,116 KB
testcase_05 AC 20 ms
9,008 KB
testcase_06 AC 20 ms
9,048 KB
testcase_07 AC 19 ms
9,036 KB
testcase_08 AC 20 ms
9,148 KB
testcase_09 AC 19 ms
9,148 KB
testcase_10 AC 19 ms
9,012 KB
testcase_11 AC 19 ms
9,000 KB
testcase_12 AC 19 ms
8,992 KB
testcase_13 AC 20 ms
9,056 KB
testcase_14 AC 20 ms
9,004 KB
testcase_15 AC 21 ms
9,000 KB
testcase_16 AC 20 ms
9,004 KB
testcase_17 AC 20 ms
9,140 KB
testcase_18 AC 20 ms
9,004 KB
testcase_19 AC 19 ms
9,048 KB
testcase_20 AC 19 ms
9,004 KB
testcase_21 AC 20 ms
9,028 KB
testcase_22 AC 20 ms
9,008 KB
testcase_23 AC 20 ms
9,160 KB
testcase_24 AC 19 ms
9,100 KB
testcase_25 AC 19 ms
9,000 KB
testcase_26 AC 20 ms
9,020 KB
testcase_27 AC 20 ms
9,040 KB
testcase_28 AC 20 ms
9,004 KB
testcase_29 AC 20 ms
9,132 KB
testcase_30 AC 20 ms
9,000 KB
testcase_31 AC 19 ms
9,196 KB
testcase_32 AC 20 ms
9,104 KB
testcase_33 AC 19 ms
9,000 KB
testcase_34 AC 19 ms
9,132 KB
testcase_35 AC 20 ms
8,984 KB
testcase_36 AC 19 ms
9,192 KB
testcase_37 AC 20 ms
9,136 KB
testcase_38 AC 20 ms
9,004 KB
testcase_39 AC 20 ms
9,200 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import Counter
from datetime import datetime, timedelta


def main():
    M, D, K = map(int, input().split())
    today_ = datetime(year=2022, month=M, day=D)
    week = [today_ + timedelta(days=days) for days in range(7)]
    week_str = list(map(lambda day: day.strftime("%m/%d"), week))
    week_str_join = "".join(week_str)

    day_str_counter = Counter(week_str_join)
    if len(list(filter(bool, (day_str_counter[str(day_num)] for day_num in range(10))))) >= K:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()
0