結果

問題 No.373 かけ算と割った余り
ユーザー fal_rndfal_rnd
提出日時 2017-03-31 15:49:15
言語 Java21
(openjdk 21)
結果
AC  
実行時間 115 ms / 2,000 ms
コード長 339 bytes
コンパイル時間 1,789 ms
コンパイル使用メモリ 70,912 KB
実行使用メモリ 56,132 KB
最終ジャッジ日時 2023-09-21 10:39:19
合計ジャッジ時間 3,241 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 114 ms
55,968 KB
testcase_01 AC 115 ms
56,132 KB
testcase_02 AC 112 ms
55,952 KB
testcase_03 AC 113 ms
55,932 KB
testcase_04 AC 113 ms
55,604 KB
testcase_05 AC 114 ms
55,672 KB
testcase_06 AC 113 ms
55,656 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main{

	static Scanner s=new Scanner(System.in);

	public static void main(String __[]){
		input();
		solve();
	}

	private static void input(){
	}

	private static void solve(){
		long a=s.nextLong()*s.nextLong(),c=s.nextLong(),d=s.nextLong();
		a%=d;
		a*=c;
		a%=d;
		System.out.println(a);
	}
}
0