結果

問題 No.2007 Arbitrary Mod (Easy)
ユーザー sysnote8mainsysnote8main
提出日時 2023-05-07 17:04:30
言語 Java21
(openjdk 21)
結果
AC  
実行時間 43 ms / 2,000 ms
コード長 577 bytes
コンパイル時間 3,360 ms
コンパイル使用メモリ 71,756 KB
実行使用メモリ 50,192 KB
最終ジャッジ日時 2023-08-16 06:04:10
合計ジャッジ時間 8,865 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 41 ms
49,504 KB
testcase_01 AC 40 ms
50,004 KB
testcase_02 AC 41 ms
49,520 KB
testcase_03 AC 41 ms
49,636 KB
testcase_04 AC 41 ms
49,676 KB
testcase_05 AC 41 ms
49,592 KB
testcase_06 AC 42 ms
49,688 KB
testcase_07 AC 41 ms
49,652 KB
testcase_08 AC 40 ms
49,516 KB
testcase_09 AC 42 ms
49,536 KB
testcase_10 AC 40 ms
49,592 KB
testcase_11 AC 41 ms
49,860 KB
testcase_12 AC 41 ms
49,708 KB
testcase_13 AC 42 ms
50,192 KB
testcase_14 AC 41 ms
49,484 KB
testcase_15 AC 40 ms
49,776 KB
testcase_16 AC 41 ms
50,008 KB
testcase_17 AC 41 ms
49,708 KB
testcase_18 AC 42 ms
47,988 KB
testcase_19 AC 40 ms
49,788 KB
testcase_20 AC 42 ms
49,432 KB
testcase_21 AC 41 ms
49,696 KB
testcase_22 AC 43 ms
49,756 KB
testcase_23 AC 42 ms
49,548 KB
testcase_24 AC 41 ms
49,712 KB
testcase_25 AC 42 ms
49,804 KB
testcase_26 AC 41 ms
49,640 KB
testcase_27 AC 40 ms
49,696 KB
testcase_28 AC 41 ms
49,592 KB
testcase_29 AC 42 ms
49,644 KB
testcase_30 AC 41 ms
49,700 KB
testcase_31 AC 41 ms
49,488 KB
testcase_32 AC 41 ms
49,596 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