結果

問題 No.570 3人兄弟(その1)
ユーザー bluemeganebluemegane
提出日時 2018-09-10 19:13:09
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 62 ms / 2,000 ms
コード長 472 bytes
コンパイル時間 4,657 ms
コンパイル使用メモリ 109,088 KB
実行使用メモリ 23,856 KB
最終ジャッジ日時 2023-08-29 01:24:48
合計ジャッジ時間 4,555 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 62 ms
23,856 KB
testcase_01 AC 59 ms
21,696 KB
testcase_02 AC 60 ms
19,728 KB
testcase_03 AC 60 ms
21,692 KB
testcase_04 AC 60 ms
21,716 KB
testcase_05 AC 60 ms
21,824 KB
testcase_06 AC 60 ms
21,868 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System.Linq;
using System;

public class P
{
    public char n { get; set; }
    public int h { get; set; }
}

public class Hello
{
    public static void Main()
    {
        var name = new char[] { 'A', 'B', 'C' };
        var ps = new P[3];
        for (int i = 0; i < 3; i++)
            ps[i] = new P { n = name[i], h = int.Parse(Console.ReadLine().Trim()) };
        foreach (var x in ps.OrderByDescending(y =>y.h))
            Console.WriteLine(x.n);
    }
}
0