結果
問題 | No.373 かけ算と割った余り |
ユーザー |
![]() |
提出日時 | 2016-06-08 14:41:45 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 136 ms / 2,000 ms |
コード長 | 453 bytes |
コンパイル時間 | 2,030 ms |
コンパイル使用メモリ | 74,236 KB |
実行使用メモリ | 41,536 KB |
最終ジャッジ日時 | 2024-10-09 06:11:50 |
合計ジャッジ時間 | 3,627 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 5 |
ソースコード
import java.math.BigInteger; import java.util.Scanner; public class Main { public static void main (String[] args) { Scanner sc = new Scanner(System.in); BigInteger a = BigInteger.valueOf(sc.nextInt()); BigInteger b = BigInteger.valueOf(sc.nextInt()); BigInteger c = BigInteger.valueOf(sc.nextInt()); BigInteger d = BigInteger.valueOf(sc.nextInt()); System.out.println(a.multiply(b).multiply(c).remainder(d)); sc.close(); } }