結果
問題 |
No.604 誕生日のお小遣い
|
ユーザー |
![]() |
提出日時 | 2019-08-04 15:55:42 |
言語 | Java (openjdk 23) |
結果 |
WA
|
実行時間 | - |
コード長 | 311 bytes |
コンパイル時間 | 2,016 ms |
コンパイル使用メモリ | 73,980 KB |
実行使用メモリ | 41,748 KB |
最終ジャッジ日時 | 2024-07-08 09:18:56 |
合計ジャッジ時間 | 5,447 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 WA * 2 |
other | AC * 4 WA * 17 |
ソースコード
import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); long a = sc.nextLong(); long b = sc.nextLong(); long c = sc.nextLong(); long ans = c / (a - 1 + b); ans += (c - ans * (a - 1 + b)); System.out.println(ans); } }