結果
問題 |
No.146 試験監督(1)
|
ユーザー |
![]() |
提出日時 | 2017-01-21 16:22:33 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 43 ms / 1,000 ms |
コード長 | 367 bytes |
コンパイル時間 | 1,508 ms |
コンパイル使用メモリ | 157,276 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-23 04:21:22 |
合計ジャッジ時間 | 2,133 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 3 |
ソースコード
#include <bits/stdc++.h> using namespace std; using ll = long long int; using ull = unsigned long long int; const char en ='\n'; const int mod=1000000007; int main(){ cin.tie(); ios::sync_with_stdio(false); ll n,c,d; cin>>n; ll sum=0; for(int i=0;i<n;i++){ cin>>c>>d; sum+=(((c+1)/2)%mod)*(d%mod); sum%=mod; } cout<<sum<<en; return 0; }