結果
| 問題 |
No.146 試験監督(1)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-03-31 11:39:24 |
| 言語 | Java (openjdk 23) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 418 bytes |
| コンパイル時間 | 2,149 ms |
| コンパイル使用メモリ | 74,260 KB |
| 実行使用メモリ | 71,772 KB |
| 最終ジャッジ日時 | 2024-10-02 08:23:05 |
| 合計ジャッジ時間 | 6,735 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 1 TLE * 2 |
ソースコード
package yukicoder146;
import java.util.Scanner;
public class Main {
public static void main(String[] args){
Scanner sc=new Scanner(System.in);
long n=sc.nextLong();
long sum=0;
long mod=(long)Math.pow(10, 9)+7;
for(int i=0;i<n;i++){
long c=sc.nextLong();//C個の椅子がある机が
long d=sc.nextLong();//D個ある。
sum+=(((c+1)/2)*d)%mod;
sum=sum%mod;
}
System.out.println(sum);
}
}