結果

問題 No.338 アンケート機能
ユーザー kenji_shioyakenji_shioya
提出日時 2016-06-24 06:48:37
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 483 bytes
コンパイル時間 3,407 ms
コンパイル使用メモリ 74,748 KB
実行使用メモリ 54,428 KB
最終ジャッジ日時 2024-04-20 01:21:31
合計ジャッジ時間 8,738 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 137 ms
53,728 KB
testcase_01 AC 132 ms
53,824 KB
testcase_02 AC 130 ms
54,120 KB
testcase_03 AC 136 ms
54,360 KB
testcase_04 WA -
testcase_05 AC 137 ms
54,096 KB
testcase_06 WA -
testcase_07 AC 110 ms
53,116 KB
testcase_08 AC 132 ms
54,240 KB
testcase_09 AC 136 ms
54,080 KB
testcase_10 AC 114 ms
53,340 KB
testcase_11 AC 136 ms
54,136 KB
testcase_12 AC 115 ms
53,160 KB
testcase_13 AC 137 ms
53,940 KB
testcase_14 AC 130 ms
54,012 KB
testcase_15 AC 139 ms
54,428 KB
testcase_16 AC 126 ms
54,084 KB
testcase_17 AC 135 ms
54,228 KB
testcase_18 AC 125 ms
53,856 KB
testcase_19 AC 137 ms
54,228 KB
testcase_20 AC 130 ms
54,160 KB
testcase_21 AC 116 ms
53,076 KB
testcase_22 AC 119 ms
53,152 KB
testcase_23 AC 130 ms
54,128 KB
testcase_24 AC 138 ms
54,248 KB
testcase_25 AC 135 ms
53,184 KB
testcase_26 AC 113 ms
53,172 KB
testcase_27 AC 130 ms
53,772 KB
testcase_28 AC 137 ms
54,052 KB
testcase_29 AC 128 ms
54,176 KB
testcase_30 AC 137 ms
54,368 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Exercise119{
  public static void main (String[] args){

    Scanner sc = new Scanner(System.in);

    int ca = sc.nextInt();
    int cb = sc.nextInt();
    int min = 200;
    for(double i = 1; i < 200; i++){
      for(double j = 1; j < 200; j++){
        if(ca == (int)Math.round(i * 100 / (i + j)) && cb == (int)Math.round(j * 100 / (i + j))){
          min = Math.min(min, (int)(i + j));
        }
      }
    }
    System.out.println(min);
  }
}
0