結果
| 問題 | No.72 そろばん Med | 
| コンテスト | |
| ユーザー |  | 
| 提出日時 | 2016-04-14 09:49:44 | 
| 言語 | Java (openjdk 23) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 126 ms / 5,000 ms | 
| コード長 | 468 bytes | 
| コンパイル時間 | 2,013 ms | 
| コンパイル使用メモリ | 74,452 KB | 
| 実行使用メモリ | 41,448 KB | 
| 最終ジャッジ日時 | 2024-11-21 11:54:39 | 
| 合計ジャッジ時間 | 6,209 ms | 
| ジャッジサーバーID (参考情報) | judge3 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 24 | 
ソースコード
import java.math.BigInteger;
import java.util.Scanner;
public class Main {
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		BigInteger N = new BigInteger(scanner.next());
		BigInteger two = new BigInteger("2");
		BigInteger three = new BigInteger("3");
		BigInteger mod = new BigInteger("1000007");
		System.out
				.println((N.add(three).divide(two).multiply(N.add(two).divide(two)).subtract(BigInteger.ONE)).mod(mod));
	}
}
            
            
            
        