結果
| 問題 | No.1915 Addition |
| コンテスト | |
| ユーザー |
shojin_pro
|
| 提出日時 | 2022-04-29 22:04:25 |
| 言語 | Java (openjdk 25.0.2) |
| 結果 |
AC
|
| 実行時間 | 65 ms / 2,000 ms |
| コード長 | 436 bytes |
| 記録 | |
| コンパイル時間 | 2,751 ms |
| コンパイル使用メモリ | 85,688 KB |
| 実行使用メモリ | 46,912 KB |
| 最終ジャッジ日時 | 2026-03-18 13:01:42 |
| 合計ジャッジ時間 | 3,126 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 10 |
ソースコード
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
// Your code here!
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
for(int i = 0; i < n; i++){
int a = sc.nextInt();
if(a % 2 == 0){
System.out.println(a/2);
}else{
System.out.println(a*2);
}
}
}
}
shojin_pro