結果

問題 No.46 はじめのn歩
ユーザー shrnshrn
提出日時 2022-06-24 19:25:06
言語 C#
(.NET 8.0.203)
結果
AC  
実行時間 54 ms / 5,000 ms
コード長 436 bytes
コンパイル時間 14,382 ms
コンパイル使用メモリ 168,132 KB
実行使用メモリ 186,076 KB
最終ジャッジ日時 2024-04-26 03:16:01
合計ジャッジ時間 9,463 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 51 ms
28,416 KB
testcase_01 AC 51 ms
28,672 KB
testcase_02 AC 50 ms
28,544 KB
testcase_03 AC 51 ms
28,672 KB
testcase_04 AC 51 ms
28,672 KB
testcase_05 AC 50 ms
28,416 KB
testcase_06 AC 50 ms
28,928 KB
testcase_07 AC 54 ms
28,544 KB
testcase_08 AC 49 ms
29,184 KB
testcase_09 AC 49 ms
186,076 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /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 Program
{
  class Program
  {
    static void Main()
    {
		string line=Console.ReadLine();
		string[] words = line.Split(' ');
		int number1=int.Parse(words[0]);
		int number2=int.Parse(words[1]);
		int waru=number2/number1;
		int amari=number2%number1;
		if (amari==0)
		{
		    Console.WriteLine(waru.ToString());
		}
		else
		{
		    int ans=waru+1;
		    Console.WriteLine(ans.ToString());
		}
    }
  }
}
0