結果

問題 No.1131 Deviation Score
ユーザー face4face4
提出日時 2020-08-02 14:28:09
言語 Java21
(openjdk 21)
結果
AC  
実行時間 643 ms / 2,000 ms
コード長 657 bytes
コンパイル時間 2,612 ms
コンパイル使用メモリ 72,420 KB
実行使用メモリ 69,416 KB
最終ジャッジ日時 2023-09-10 12:24:17
合計ジャッジ時間 12,423 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 254 ms
56,780 KB
testcase_01 AC 109 ms
51,140 KB
testcase_02 AC 574 ms
65,596 KB
testcase_03 AC 341 ms
60,940 KB
testcase_04 AC 558 ms
66,400 KB
testcase_05 AC 293 ms
59,140 KB
testcase_06 AC 592 ms
63,496 KB
testcase_07 AC 360 ms
62,740 KB
testcase_08 AC 546 ms
68,428 KB
testcase_09 AC 289 ms
58,520 KB
testcase_10 AC 576 ms
67,096 KB
testcase_11 AC 528 ms
64,808 KB
testcase_12 AC 512 ms
63,848 KB
testcase_13 AC 602 ms
65,968 KB
testcase_14 AC 239 ms
56,520 KB
testcase_15 AC 238 ms
56,640 KB
testcase_16 AC 551 ms
64,348 KB
testcase_17 AC 297 ms
59,068 KB
testcase_18 AC 643 ms
69,416 KB
testcase_19 AC 74 ms
49,684 KB
testcase_20 AC 41 ms
49,164 KB
testcase_21 AC 42 ms
49,352 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.*;
import java.util.ArrayList;

public class Main {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int n = Integer.parseInt(br.readLine());
        ArrayList<Integer> arr = new ArrayList<Integer>(n);
        String line[] = br.readLine().split(" ");
        double sum = 0;
        for(int i = 0; i < n; i++){
            arr.add(Integer.parseInt(line[i]));
            sum += arr.get(i);
        }
        sum /= n;
        for(int i = 0; i < n; i++){
            System.out.println((int)(50.0-(sum-arr.get(i))/2));
        }
    }
}
0