結果

問題 No.48 ロボットの操縦
ユーザー Onju
提出日時 2015-02-15 05:23:14
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 205 bytes
コンパイル時間 480 ms
コンパイル使用メモリ 59,252 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-06-23 20:20:04
合計ジャッジ時間 1,313 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 18 WA * 7
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <cmath>
using namespace std;

int main()
{
	int X, Y, L;
	cin >> X >> Y >> L;

	cout << ceil((double)abs(X) / L) + ceil((double)abs(Y) / L) + (X ? 1 : 0) << endl;

	return 0;
}
0