結果
| 問題 | No.146 試験監督(1) |
| コンテスト | |
| ユーザー |
matsuyoshi30
|
| 提出日時 | 2018-09-22 02:04:40 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 520 bytes |
| コンパイル時間 | 1,982 ms |
| コンパイル使用メモリ | 74,356 KB |
| 実行使用メモリ | 71,596 KB |
| 最終ジャッジ日時 | 2024-07-18 08:51:11 |
| 合計ジャッジ時間 | 6,571 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 3 |
ソースコード
import java.util.*;
class Main {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int n = in.nextInt();
long[] c = new long[n];
long[] d = new long[n];
for(int i=0; i<n; i++) {
c[i] = in.nextLong();
d[i] = in.nextLong();
}
long ans = 0;
for(int i=0; i<n; i++) {
long t = (c[i] - 1) / 2 + 1;
ans += t * d[i];
}
System.out.println(ans % 1000000007);
}
}
matsuyoshi30