結果

問題 No.2054 Different Sequence
ユーザー kept1994
提出日時 2022-11-04 02:05:32
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 42 ms / 2,000 ms
コード長 285 bytes
コンパイル時間 167 ms
コンパイル使用メモリ 82,432 KB
実行使用メモリ 52,480 KB
最終ジャッジ日時 2024-07-18 06:55:25
合計ジャッジ時間 1,927 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python3
def getArithmeticSequenceSum(a0: int, l: int, n: int):
    return (a0 + l) * n // 2

def main():
    N, M = map(int, input().split())
    l = getArithmeticSequenceSum(1, N, N)
    print("Yes" if M >= l else "No")
    return

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