結果
| 問題 |
No.146 試験監督(1)
|
| コンテスト | |
| ユーザー |
Tsukasa_Type
|
| 提出日時 | 2018-02-13 17:43:18 |
| 言語 | Java (openjdk 23) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 366 bytes |
| コンパイル時間 | 2,690 ms |
| コンパイル使用メモリ | 73,948 KB |
| 実行使用メモリ | 69,748 KB |
| 最終ジャッジ日時 | 2024-11-29 21:35:24 |
| 合計ジャッジ時間 | 7,885 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | TLE * 3 |
ソースコード
import java.util.*;
public class Main {
static Scanner sc = new Scanner(System.in);
public static void main(String[] args) {
int n = sc.nextInt();
long max = 0;
long mod = 1000000007;
for (int i=0; i<n; i++) {
long leng = sc.nextLong();
long num = sc.nextLong();
max += ((leng+1)/2*num%mod)%mod;
max %= mod;
}
System.out.println(max);
}
}
Tsukasa_Type