結果
| 問題 | No.2850 Make Slimes |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-12-09 09:29:03 |
| 言語 | C# (.NET 10.0.403 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 36 ms / 2,000 ms |
| + 744µs | |
| コード長 | 1,201 bytes |
| 記録 | |
| コンパイル時間 | 9,958 ms |
| コンパイル使用メモリ | 171,396 KB |
| 実行使用メモリ | 30,848 KB |
| 最終ジャッジ日時 | 2026-11-07 20:37:58 |
| 合計ジャッジ時間 | 11,778 ms |
|
ジャッジサーバーID (参考情報) |
judge4_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 9 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.csproj を復元しました (184 ミリ秒)。 main -> /home/judge/data/code/bin/Release/net10.0/main.dll main -> /home/judge/data/code/bin/Release/net10.0/publish/
ソースコード
using System.Numerics;
public class Program
{
public static void Main()
{
//BigInteger num = BigInteger.Parse(Console.ReadLine() ?? string.Empty);
//int num = int.Parse(Console.ReadLine() ?? string.Empty);
string[] str = (Console.ReadLine() ?? string.Empty).Trim().Split(' ');
//string str = Console.ReadLine() ?? string.Empty;
int a = int.Parse(str[0]);
int b = int.Parse(str[1]);
int c = int.Parse(str[2]);
int d = int.Parse(str[3]);
if(a > c||b > d)
{
Console.WriteLine(0);
}
else if(a!=0&&a ==c || b!=0&&b ==d)
{
Console.WriteLine(1);
}
else
{
if(a==0)
{
Console.WriteLine(d / b);
return;
}
else if(b==0)
{
Console.WriteLine(c / a);
return;
}
int e = c / a;
int f = d / b;
if(e > f)
{
Console.WriteLine(f);
}
else
{
Console.WriteLine(e);
}
}
}
}