結果

問題 No.276 連続する整数の和(1)
ユーザー fjafjafjafjafjafja
提出日時 2017-09-19 17:48:20
言語 Java21
(openjdk 21)
結果
AC  
実行時間 130 ms / 1,000 ms
コード長 166 bytes
コンパイル時間 1,817 ms
コンパイル使用メモリ 75,268 KB
実行使用メモリ 54,444 KB
最終ジャッジ日時 2024-04-25 18:11:50
合計ジャッジ時間 3,600 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 125 ms
54,244 KB
testcase_01 AC 130 ms
54,180 KB
testcase_02 AC 120 ms
54,444 KB
testcase_03 AC 117 ms
54,172 KB
testcase_04 AC 120 ms
54,208 KB
testcase_05 AC 119 ms
54,028 KB
testcase_06 AC 119 ms
54,112 KB
testcase_07 AC 118 ms
53,972 KB
testcase_08 AC 114 ms
54,028 KB
testcase_09 AC 122 ms
54,208 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;class A{public static void main(String[] args){Scanner sc=new Scanner(System.in);int x=sc.nextInt();x=(x%2==0)?x/2:x;System.out.println(x);}}
0