結果

問題 No.172 UFOを捕まえろ
ユーザー kou6839kou6839
提出日時 2015-03-27 00:10:51
言語 Java21
(openjdk 21)
結果
AC  
実行時間 131 ms / 5,000 ms
コード長 325 bytes
コンパイル時間 2,182 ms
コンパイル使用メモリ 74,312 KB
実行使用メモリ 41,632 KB
最終ジャッジ日時 2024-04-23 13:57:49
合計ジャッジ時間 6,049 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 129 ms
41,332 KB
testcase_01 AC 113 ms
40,212 KB
testcase_02 AC 126 ms
41,360 KB
testcase_03 AC 129 ms
41,392 KB
testcase_04 AC 126 ms
41,516 KB
testcase_05 AC 113 ms
40,140 KB
testcase_06 AC 113 ms
40,248 KB
testcase_07 AC 128 ms
41,620 KB
testcase_08 AC 114 ms
40,404 KB
testcase_09 AC 125 ms
41,528 KB
testcase_10 AC 113 ms
40,324 KB
testcase_11 AC 117 ms
39,904 KB
testcase_12 AC 116 ms
40,480 KB
testcase_13 AC 128 ms
41,132 KB
testcase_14 AC 119 ms
40,604 KB
testcase_15 AC 128 ms
41,264 KB
testcase_16 AC 125 ms
41,020 KB
testcase_17 AC 128 ms
41,288 KB
testcase_18 AC 126 ms
41,632 KB
testcase_19 AC 128 ms
41,364 KB
testcase_20 AC 129 ms
41,076 KB
testcase_21 AC 131 ms
41,476 KB
testcase_22 AC 129 ms
41,580 KB
testcase_23 AC 127 ms
41,132 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.math.BigInteger;
import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		int n=sc.nextInt();
		int m = sc.nextInt();
		int r = sc.nextInt();
		double waa = 1/Math.sqrt(2);
		System.out.println(Math.abs(n)+Math.abs(m)+(int)(Math.ceil(r/waa)));
	}
}
0