結果
問題 |
No.146 試験監督(1)
|
ユーザー |
|
提出日時 | 2016-04-15 02:35:39 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 120 ms / 1,000 ms |
コード長 | 273 bytes |
コンパイル時間 | 346 ms |
コンパイル使用メモリ | 54,744 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-10-04 09:17:42 |
合計ジャッジ時間 | 1,355 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 3 |
ソースコード
#include <iostream> using namespace std; int main() { int n, mod = 1000000007; unsigned long long int c, d, sum = 0; cin >> n; for(int i=0;i<n;++i){ cin >> c >> d; sum = (sum +(((c + 1) / 2) % mod) * (d % mod)) % mod; } cout << sum << endl; return 0; }