結果
問題 |
No.3100 Parallel Translated
|
ユーザー |
![]() |
提出日時 | 2025-01-28 22:19:17 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 38 ms / 2,000 ms |
コード長 | 294 bytes |
コンパイル時間 | 177 ms |
コンパイル使用メモリ | 82,316 KB |
実行使用メモリ | 54,500 KB |
最終ジャッジ日時 | 2025-04-11 20:50:07 |
合計ジャッジ時間 | 2,395 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 32 |
ソースコード
mod = 998244353 n = int(input()) x = [0] * n y = [0] * n for i in range(n): x[i], y[i] = map(int,input().split()) ans = 0 for i in range(n-2): ax = x[i+1] - x[0] bx = y[i+1] - y[0] ay = x[i+2] - x[0] by = y[i+2] - y[0] ans += ax * by - ay * bx ans *= pow(2, mod-2, mod) print(ans % mod)