結果

問題 No.188 HAPPY DAY
ユーザー mahnamahna
提出日時 2020-05-09 21:44:17
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 32 ms / 1,000 ms
コード長 327 bytes
コンパイル時間 93 ms
コンパイル使用メモリ 10,660 KB
実行使用メモリ 9,552 KB
最終ジャッジ日時 2023-09-20 09:23:03
合計ジャッジ時間 696 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 32 ms
9,552 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

# coding: utf-8
import calendar

month = 12
y = 2015
happy_ct = 0

for i in range(1,month + 1):
    last_day_num = calendar.monthrange(y,i)[1]
    
    for j in range(1,last_day_num):
        j_1 = j // 10
        j_2 = j % 10
        j_sum = j_1 + j_2
        
        if i == j_sum:
            happy_ct += 1

print(happy_ct)
0