結果

問題 No.734 Careful Engineer
ユーザー GrenacheGrenache
提出日時 2019-04-27 13:09:13
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 713 bytes
コンパイル時間 3,460 ms
コンパイル使用メモリ 75,896 KB
実行使用メモリ 56,228 KB
最終ジャッジ日時 2024-05-05 18:14:09
合計ジャッジ時間 6,237 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 130 ms
54,000 KB
testcase_07 AC 134 ms
53,844 KB
testcase_08 AC 131 ms
53,920 KB
testcase_09 AC 134 ms
54,256 KB
testcase_10 WA -
testcase_11 AC 134 ms
54,280 KB
testcase_12 AC 131 ms
53,980 KB
testcase_13 AC 135 ms
54,276 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.*;
import java.util.Scanner;


public class Main_yukicoder734 {

	private static Scanner sc;
	private static Printer pr;

	private static void solve() {
		int a = sc.nextInt();
		int b = sc.nextInt();
		int c = sc.nextInt();

//		60 a x >= b x + 3600c
		if (60 * a - b <= 0) {
			pr.println(-1);
		} else {
			int x = (3600 * c + 60 * a - b - 1) / (60 * a - b);
			pr.println(x);
		}
	}

	// ---------------------------------------------------
	public static void main(String[] args) {
		sc = new Scanner(System.in);
		pr = new Printer(System.out);
			
		solve();
			
		pr.close();
		sc.close();
	}

	static class Printer extends PrintWriter {
		Printer(OutputStream out) {
			super(out);
		}
	}
}
0