結果
| 問題 | No.188 HAPPY DAY | 
| コンテスト | |
| ユーザー |  | 
| 提出日時 | 2018-10-15 23:52:58 | 
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 29 ms / 1,000 ms | 
| コード長 | 662 bytes | 
| コンパイル時間 | 125 ms | 
| コンパイル使用メモリ | 12,416 KB | 
| 実行使用メモリ | 10,368 KB | 
| 最終ジャッジ日時 | 2024-10-12 18:37:35 | 
| 合計ジャッジ時間 | 501 ms | 
| ジャッジサーバーID (参考情報) | judge5 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | AC * 1 | 
ソースコード
def num_happy_day():
    month = []
    day  = []
    num = 0
    for i in range(1,13):
        month.append(i)
    for i in range(1,32):
        day.append(i)
    
    for left in month:
        for right in day:
            if left == 2 and right == 29:
                break
            elif (left == 4 and right == 31) or (left == 6 and right == 31) or (left == 9 and right == 31) or (left == 11 and right == 31):
                break
            else:
                right_ten = right // 10
                right_digit = right % 10
                if left == right_ten + right_digit:
                    num += 1
    return num
print(num_happy_day())
            
            
            
        