結果

問題 No.779 Heisei
ユーザー Haruki0804S
提出日時 2019-01-25 10:42:16
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 569 ms / 1,000 ms
コード長 649 bytes
コンパイル時間 107 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 44,468 KB
最終ジャッジ日時 2024-12-20 18:27:50
合計ジャッジ時間 15,070 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 23
権限があれば一括ダウンロードができます

ソースコード

diff #

import numpy as np 


def get_data():
    Y, M, D = input().split(' ')
    
    return int(Y), int(M), int(D)

def heisei(Y,M,D):

    if Y > 1989 and Y<2019:
        return True

    elif Y==1989:
        if M == 1:
            if D<8:
                return False
            else:
                return True
        else:
            return True
    
    elif Y==2019:
        if M<5:
            return True
        else:
            return False
    
    else:
        return False
    


def main():
    Y, M, D = get_data()
    if heisei(Y,M,D):
        print("Yes")
    else:
        print("No")
        
if __name__=='__main__':
    main()
0