結果

問題 No.857 素振り
ユーザー ruuuuutopiaruuuuutopia
提出日時 2021-06-01 21:12:41
言語 C#
(.NET 8.0.203)
結果
TLE  
実行時間 -
コード長 585 bytes
コンパイル時間 8,064 ms
コンパイル使用メモリ 168,012 KB
実行使用メモリ 35,840 KB
最終ジャッジ日時 2024-04-26 09:51:32
合計ジャッジ時間 10,899 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 46 ms
32,104 KB
testcase_01 AC 45 ms
34,304 KB
testcase_02 AC 43 ms
29,184 KB
testcase_03 AC 43 ms
28,800 KB
testcase_04 TLE -
testcase_05 -- -
testcase_06 -- -
testcase_07 -- -
testcase_08 -- -
testcase_09 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.csproj を復元しました (104 ms)。
MSBuild のバージョン 17.9.6+a4ecab324 (.NET)
  main -> /home/judge/data/code/bin/Release/net8.0/main.dll
  main -> /home/judge/data/code/bin/Release/net8.0/publish/

ソースコード

diff #

using System;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] inputA = Console.ReadLine().Split(' ');
            long X = long.Parse(inputA[0])-1;
            long Y = long.Parse(inputA[1])-1;
            long Z = long.Parse(inputA[2]);
            long count = 0;
            for(long i = 0; i < Z; i++)
            {
                count++;
                if (i==X ||i==Y)
                {
                    count--;
                }
            }

            Console.WriteLine(count);
        }
    }
}
0