結果
| 問題 |
No.48 ロボットの操縦
|
| コンテスト | |
| ユーザー |
btk
|
| 提出日時 | 2015-05-22 10:56:46 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 5,000 ms |
| コード長 | 207 bytes |
| コンパイル時間 | 446 ms |
| コンパイル使用メモリ | 55,116 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-11-21 18:20:30 |
| 合計ジャッジ時間 | 1,230 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 25 |
ソースコード
#include<iostream>
using namespace std;
int main(){
int x,y,l;
cin>>x>>y>>l;
int cnt=0;
if(x)cnt=1;
if(x<0)x*=-1;
if(y<0){
cnt=2;
y*=-1;
}
cnt+=(y+l-1)/l;
cnt+=(x+l-1)/l;
cout<<cnt<<endl;
}
btk