結果

問題 No.63 ポッキーゲーム
ユーザー kachipan
提出日時 2023-06-23 11:21:09
言語 C
(gcc 13.3.0)
結果
RE  
実行時間 -
コード長 327 bytes
コンパイル時間 186 ms
コンパイル使用メモリ 27,392 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-06-30 16:27:15
合計ジャッジ時間 3,784 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other RE * 22
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>

int main()
{
	int length = 0;
	int eatLength = 0;

	int eatCnt = 0;

	scanf("%d", length);
	scanf("%d", eatLength);

	while (true)
	{
		if (eatCnt + eatLength < length / 2)
		{
			eatCnt += eatLength;
		}
		else
		{
			printf("%d\n", eatCnt);
			return 0;
		}
	}
}

0