結果
| 問題 |
No.2259 Gas Station
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2023-04-17 22:39:12 |
| 言語 | C (gcc 13.3.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 716 bytes |
| コンパイル時間 | 160 ms |
| コンパイル使用メモリ | 29,312 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-12 22:44:46 |
| 合計ジャッジ時間 | 11,407 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 8 WA * 10 TLE * 3 |
ソースコード
#include<stdio.h>
//#include<time.h>
//#include<stdlib.h>
int main(void){
//srand(time(NULL));
int L,R,C,x;
int oturi,min;
//int second;
scanf("%lld %lld %lld",&L,&R,&C);
min = 999;
//while(second < 2){
//second = time(NULL);
//L = rand();
//R = rand();
//C = rand();
for(x = L;x <= R;x++){
oturi = ((1000 - ((x*C) % 1000)) % 1000);
if(oturi < min){
min = oturi;
}
}
//printf("L:%d R:%d C:%d\n",L,R,C);
printf("%d\n",min);
//second = time(NULL) - second;
//printf("経過時間:%d\n",second);
//printf("\n");
//}
return 0;
}