結果

問題 No.9009 改行区切りで与えられる数値データの合計値を求める(テスト用)
ユーザー くれちーくれちー
提出日時 2017-03-25 19:32:17
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 189 ms / 3,000 ms
コード長 454 bytes
コンパイル時間 3,920 ms
コンパイル使用メモリ 103,096 KB
実行使用メモリ 56,628 KB
最終ジャッジ日時 2023-08-26 16:58:34
合計ジャッジ時間 5,933 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 55 ms
21,796 KB
testcase_01 AC 56 ms
21,840 KB
testcase_02 AC 59 ms
23,828 KB
testcase_03 AC 57 ms
19,784 KB
testcase_04 AC 54 ms
21,788 KB
testcase_05 AC 55 ms
23,828 KB
testcase_06 AC 64 ms
21,988 KB
testcase_07 AC 65 ms
23,012 KB
testcase_08 AC 85 ms
28,444 KB
testcase_09 AC 106 ms
37,600 KB
testcase_10 AC 179 ms
53,288 KB
testcase_11 AC 183 ms
53,852 KB
testcase_12 AC 186 ms
54,432 KB
testcase_13 AC 185 ms
54,952 KB
testcase_14 AC 181 ms
54,128 KB
testcase_15 AC 182 ms
56,628 KB
testcase_16 AC 189 ms
54,940 KB
testcase_17 AC 55 ms
23,832 KB
testcase_18 AC 56 ms
19,708 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.IO;
using System.Linq;

class Program
{
    static void Main()
    {
        using (var sr = new StreamReader(Console.OpenStandardInput()))
        {
            sr.ReadLine();
            var a = sr.ReadToEnd()
                .Split(new string[] { Environment.NewLine },
                    StringSplitOptions.RemoveEmptyEntries)
                .Select(long.Parse);

            Console.WriteLine(a.Sum());
        }
    }
}
0