結果

問題 No.735 接線
ユーザー Mcpu3
提出日時 2018-09-29 00:17:09
言語 Java
(openjdk 23)
結果
AC  
実行時間 150 ms / 2,000 ms
コード長 293 bytes
コンパイル時間 2,143 ms
コンパイル使用メモリ 74,476 KB
実行使用メモリ 42,000 KB
最終ジャッジ日時 2024-10-12 07:45:26
合計ジャッジ時間 7,441 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        double r = sc.nextDouble(), d = sc.nextDouble();
        sc.close();
        System.out.print(Math.sqrt(Math.pow(d, 2) - Math.pow(r, 2)));
    }
}
0