結果

問題 No.218 経験値1.5倍
ユーザー ontama_12ontama_12
提出日時 2016-09-23 11:26:51
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 936 bytes
コンパイル時間 2,196 ms
コンパイル使用メモリ 74,276 KB
実行使用メモリ 41,512 KB
最終ジャッジ日時 2024-04-28 21:26:52
合計ジャッジ時間 7,257 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 128 ms
41,324 KB
testcase_01 AC 115 ms
39,792 KB
testcase_02 AC 129 ms
41,012 KB
testcase_03 AC 129 ms
41,032 KB
testcase_04 AC 128 ms
41,088 KB
testcase_05 AC 115 ms
39,988 KB
testcase_06 WA -
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 AC 115 ms
40,492 KB
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 AC 129 ms
41,224 KB
testcase_16 WA -
testcase_17 WA -
testcase_18 AC 131 ms
41,212 KB
testcase_19 WA -
testcase_20 AC 132 ms
41,004 KB
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 WA -
testcase_25 WA -
testcase_26 AC 130 ms
41,140 KB
testcase_27 WA -
testcase_28 AC 132 ms
41,092 KB
testcase_29 AC 131 ms
41,152 KB
testcase_30 AC 128 ms
41,180 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
//入力文字をの読み取り
    	Scanner sc = new Scanner(System.in);
        //1文字目
        long a = sc.nextLong();
        //2文字目
        long b = sc.nextLong();
        //3文字目
        long c = sc.nextLong();


        //通常での必要な素材数
        long nomal = a/b;
        int nomalremain = (int) (a%b);
      //余りが出ると+1
        if(nomalremain !=0){
        	nomal = nomal+1;
        }

        //キャンペーン期間での必要な素材数
        long campaign = a%c;
        int campaignremain = (int) (a%b);
        //余りが出ると+1
        if(campaignremain !=0){
        	campaign = campaign+1;
        }

        //仮設を計算出力
       if (nomal<=campaign/2*3){
    		System.out.println("YES");
       }
       else{
    	   System.out.println("NO");
       }
    }
}
0