結果

問題 No.1134 Deviation Score Ⅱ
ユーザー keymoonkeymoon
提出日時 2021-01-15 00:17:16
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 101 ms / 2,000 ms
コード長 719 bytes
コンパイル時間 4,534 ms
コンパイル使用メモリ 106,664 KB
実行使用メモリ 28,860 KB
最終ジャッジ日時 2023-08-16 08:03:06
合計ジャッジ時間 5,972 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 61 ms
23,976 KB
testcase_01 AC 94 ms
28,664 KB
testcase_02 AC 86 ms
26,176 KB
testcase_03 AC 91 ms
26,444 KB
testcase_04 AC 78 ms
21,004 KB
testcase_05 AC 94 ms
26,868 KB
testcase_06 AC 79 ms
24,860 KB
testcase_07 AC 73 ms
22,708 KB
testcase_08 AC 90 ms
26,412 KB
testcase_09 AC 73 ms
22,472 KB
testcase_10 AC 69 ms
24,140 KB
testcase_11 AC 85 ms
23,980 KB
testcase_12 AC 85 ms
24,012 KB
testcase_13 AC 96 ms
28,860 KB
testcase_14 AC 84 ms
24,080 KB
testcase_15 AC 81 ms
23,164 KB
testcase_16 AC 74 ms
22,712 KB
testcase_17 AC 86 ms
23,940 KB
testcase_18 AC 85 ms
24,064 KB
testcase_19 AC 92 ms
26,480 KB
testcase_20 AC 80 ms
21,544 KB
testcase_21 AC 93 ms
26,688 KB
testcase_22 AC 89 ms
24,072 KB
testcase_23 AC 62 ms
22,012 KB
testcase_24 AC 62 ms
21,928 KB
testcase_25 AC 73 ms
22,492 KB
testcase_26 AC 101 ms
27,360 KB
testcase_27 AC 61 ms
21,896 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Numerics;
using System.Text;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using static System.Math;
public static class P
{
    public static void Main()
    {
        int n = int.Parse(Console.ReadLine());
        var a = Console.ReadLine().Split().Select(int.Parse).ToArray();
        var m = int.Parse(Console.ReadLine());
        var avg = a.Average();
        var sd = Sqrt(a.Average(x => Pow(avg - x, 2)));
        var res = sd != 0 ? 50 + (a[m - 1] - avg) / sd * 10 : 50;
        Console.WriteLine((int)Floor(Abs(res)) * Sign(res));
    }
}
0