結果

問題 No.98 円を描こう
ユーザー mits58
提出日時 2016-07-02 20:15:54
言語 Java
(openjdk 23)
結果
AC  
実行時間 139 ms / 5,000 ms
コード長 279 bytes
コンパイル時間 1,950 ms
コンパイル使用メモリ 75,024 KB
実行使用メモリ 41,820 KB
最終ジャッジ日時 2024-10-12 01:16:23
合計ジャッジ時間 4,101 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class Main{
	public static void main(String[] args){
		Scanner sc=new Scanner(System.in);
		while(sc.hasNext()){
			double x=sc.nextDouble();
			double y=sc.nextDouble();
			int r=(int)Math.sqrt(4*x*x+4*y*y);
			System.out.println(r+1);
		}
	}
}
0