結果

問題 No.276 連続する整数の和(1)
ユーザー hayashihayashi
提出日時 2019-11-01 10:25:41
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 57 ms / 1,000 ms
コード長 402 bytes
コンパイル時間 3,570 ms
コンパイル使用メモリ 98,936 KB
実行使用メモリ 22,732 KB
最終ジャッジ日時 2023-10-13 00:38:10
合計ジャッジ時間 4,440 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 55 ms
22,716 KB
testcase_01 AC 56 ms
20,592 KB
testcase_02 AC 56 ms
20,720 KB
testcase_03 AC 55 ms
22,732 KB
testcase_04 AC 57 ms
20,640 KB
testcase_05 AC 55 ms
20,564 KB
testcase_06 AC 55 ms
22,608 KB
testcase_07 AC 55 ms
22,600 KB
testcase_08 AC 55 ms
20,752 KB
testcase_09 AC 54 ms
20,564 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 static System.Console;
namespace ConsoleApp
{
    class Program
    {
        static void Main(string[] args)
        {
            ulong N = ulong.Parse(ReadLine());
            if(N % 2 == 0)
            {
                WriteLine(N / 2);
            }
            else
            {
                WriteLine(N);
            }
        }
    }
}
0