結果

問題 No.2007 Arbitrary Mod (Easy)
ユーザー sysnote8mainsysnote8main
提出日時 2023-05-07 17:04:30
言語 Java21
(openjdk 21)
結果
AC  
実行時間 57 ms / 2,000 ms
コード長 577 bytes
コンパイル時間 3,368 ms
コンパイル使用メモリ 74,812 KB
実行使用メモリ 50,704 KB
最終ジャッジ日時 2024-05-03 15:11:35
合計ジャッジ時間 7,555 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 54 ms
50,456 KB
testcase_01 AC 53 ms
50,276 KB
testcase_02 AC 54 ms
50,188 KB
testcase_03 AC 54 ms
50,616 KB
testcase_04 AC 54 ms
50,440 KB
testcase_05 AC 54 ms
50,556 KB
testcase_06 AC 53 ms
50,364 KB
testcase_07 AC 54 ms
50,640 KB
testcase_08 AC 55 ms
50,404 KB
testcase_09 AC 54 ms
50,548 KB
testcase_10 AC 54 ms
50,704 KB
testcase_11 AC 55 ms
50,432 KB
testcase_12 AC 54 ms
50,044 KB
testcase_13 AC 55 ms
50,460 KB
testcase_14 AC 53 ms
50,248 KB
testcase_15 AC 54 ms
50,512 KB
testcase_16 AC 54 ms
50,616 KB
testcase_17 AC 57 ms
50,132 KB
testcase_18 AC 54 ms
50,400 KB
testcase_19 AC 54 ms
50,504 KB
testcase_20 AC 56 ms
50,572 KB
testcase_21 AC 54 ms
50,536 KB
testcase_22 AC 55 ms
50,552 KB
testcase_23 AC 55 ms
50,076 KB
testcase_24 AC 54 ms
50,516 KB
testcase_25 AC 54 ms
50,312 KB
testcase_26 AC 55 ms
50,448 KB
testcase_27 AC 55 ms
50,192 KB
testcase_28 AC 55 ms
50,388 KB
testcase_29 AC 53 ms
50,432 KB
testcase_30 AC 54 ms
50,536 KB
testcase_31 AC 55 ms
50,448 KB
testcase_32 AC 54 ms
50,704 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.math.BigInteger;

public class Arbitrary_Mod_2007{
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] il = br.readLine().split(" ");
        BigInteger p = new BigInteger(il[0]);
        BigInteger q = new BigInteger(il[1]);
        BigInteger g = new BigInteger("10000000000");
        System.out.println(g);
        System.out.println(p.modPow(q,g));
    }
}
0