結果

問題 No.9001 標準入出力の練習問題(テスト用)
ユーザー くれちーくれちー
提出日時 2017-05-14 01:53:22
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 65 ms / 1,000 ms
コード長 686 bytes
コンパイル時間 4,957 ms
コンパイル使用メモリ 102,516 KB
実行使用メモリ 22,836 KB
最終ジャッジ日時 2023-10-13 16:21:09
合計ジャッジ時間 4,573 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 65 ms
22,820 KB
testcase_01 AC 63 ms
22,836 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.Generic;
using System.IO;
using System.Linq;
using static Extensions;

static class Extensions
{
    public static void GetNums<T1, T2>(out T1 dest1, out T2 dest2)
    {
        var str = Console.ReadLine().Split();
        dest1 = (T1)typeof(T1).GetMethod("Parse", new Type[] { typeof(string) }).Invoke(null, new object[] { str[0] });
        dest2 = (T2)typeof(T2).GetMethod("Parse", new Type[] { typeof(string) }).Invoke(null, new object[] { str[1] });
    }
}

class Program
{
    static void Main()
    {
        int a, b;
        GetNums(out a, out b);
        Console.Write((a + b) + " ");
        Console.Write(Console.ReadLine());
    }
}
0