結果

問題 No.388 階段 (1)
ユーザー Numa
提出日時 2017-08-23 22:44:57
言語 C
(gcc 13.3.0)
結果
AC  
実行時間 1 ms / 2,000 ms
コード長 241 bytes
コンパイル時間 107 ms
コンパイル使用メモリ 27,904 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-10-15 13:38:59
合計ジャッジ時間 714 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 12
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>

int main()
{
	int s,f,n=1;
	
	scanf("%d%d",&s,&f);
	
	if(s==f)
	{
		printf("%d",n+1);
	}
	else if(s<f)
	{
		printf("%d",n);
	}
	else if(s>f)
	{
		while(s>=f)
		{
			s=s-f;
			n=n+1;
		}
		printf("%d",n);
	}
	
	return 0;
}
0