結果

問題 No.306 さいたま2008
ユーザー spaciaspacia
提出日時 2016-01-18 22:56:29
言語 Java21
(openjdk 21)
結果
AC  
実行時間 60 ms / 2,000 ms
コード長 576 bytes
コンパイル時間 2,131 ms
コンパイル使用メモリ 74,468 KB
実行使用メモリ 53,556 KB
最終ジャッジ日時 2023-10-21 06:49:39
合計ジャッジ時間 4,861 ms
ジャッジサーバーID
(参考情報)
judge10 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 58 ms
52,516 KB
testcase_01 AC 56 ms
53,536 KB
testcase_02 AC 56 ms
53,544 KB
testcase_03 AC 60 ms
53,544 KB
testcase_04 AC 55 ms
53,552 KB
testcase_05 AC 57 ms
53,540 KB
testcase_06 AC 58 ms
52,480 KB
testcase_07 AC 57 ms
53,544 KB
testcase_08 AC 56 ms
53,556 KB
testcase_09 AC 58 ms
52,444 KB
testcase_10 AC 57 ms
52,444 KB
testcase_11 AC 57 ms
53,548 KB
testcase_12 AC 56 ms
53,536 KB
testcase_13 AC 56 ms
52,488 KB
testcase_14 AC 58 ms
52,500 KB
testcase_15 AC 56 ms
51,564 KB
testcase_16 AC 56 ms
53,540 KB
testcase_17 AC 59 ms
52,472 KB
testcase_18 AC 56 ms
53,544 KB
testcase_19 AC 56 ms
52,548 KB
testcase_20 AC 56 ms
52,508 KB
testcase_21 AC 58 ms
53,548 KB
testcase_22 AC 57 ms
52,448 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.*;
import java.util.*;
import java.math.*;

class Main {
	
	public static void out (Object o) {
		System.out.println(o);
	}
	
	public static void main (String[] args) throws IOException {
		BufferedReader br = 
			new BufferedReader(new InputStreamReader(System.in));
		
		String[] line = br.readLine().split(" ");
		int xa = Integer.parseInt(line[0]);
		int ya = Integer.parseInt(line[1]);
		line = br.readLine().split(" ");
		int xb = Integer.parseInt(line[0]);
		int yb = Integer.parseInt(line[1]);
		
		out(yb + xb * ((double)(ya - yb) / (xa + xb)));
	}
	
}
0