結果
問題 | No.2649 [Cherry 6th Tune C] Anthem Flower |
ユーザー |
|
提出日時 | 2024-12-07 11:11:34 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 652 ms / 2,000 ms |
コード長 | 248 bytes |
コンパイル時間 | 416 ms |
コンパイル使用メモリ | 81,920 KB |
実行使用メモリ | 79,872 KB |
最終ジャッジ日時 | 2024-12-07 11:11:46 |
合計ジャッジ時間 | 10,672 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 35 |
ソースコード
import sys sys.set_int_max_str_digits(0) def solve(): N, M = map(int, input().split()) ans = N * (N + 1) // 2 print(ans % M) def main(): T = int(input()) for i in range(T): solve() if __name__ == '__main__': main()