結果

問題 No.373 かけ算と割った余り
ユーザー 37zigen37zigen
提出日時 2016-06-04 23:04:59
言語 Java21
(openjdk 21)
結果
AC  
実行時間 130 ms / 2,000 ms
コード長 352 bytes
コンパイル時間 2,590 ms
コンパイル使用メモリ 73,840 KB
実行使用メモリ 41,732 KB
最終ジャッジ日時 2024-04-17 11:00:27
合計ジャッジ時間 3,360 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 126 ms
41,548 KB
testcase_01 AC 127 ms
41,732 KB
testcase_02 AC 127 ms
41,328 KB
testcase_03 AC 126 ms
41,412 KB
testcase_04 AC 116 ms
41,300 KB
testcase_05 AC 130 ms
41,252 KB
testcase_06 AC 122 ms
40,104 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package yukicoder;
import java.util.Scanner;
public class Main{
	public static void main(String[] args){
		new Main().solve();
	}
	void solve(){
		Scanner sc=new Scanner(System.in);
		long a,b,c,d;
		a=sc.nextLong();b=sc.nextLong();c=sc.nextLong();d=sc.nextLong();
		long ans=1;
		ans=a%d;
		ans=ans*b%d;
		ans=ans*c%d;
		System.out.println(ans);
	}
}
0