結果
問題 | No.48 ロボットの操縦 |
ユーザー |
![]() |
提出日時 | 2020-03-22 15:23:34 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 302 bytes |
コンパイル時間 | 1,481 ms |
コンパイル使用メモリ | 165,600 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-24 17:58:33 |
合計ジャッジ時間 | 2,281 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 24 WA * 1 |
ソースコード
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(0); int64_t X, Y, L; cin >> X >> Y >> L; int res = 0; if (Y < 0) res++; if (X != 0) res++; res += (abs(X) + L - 1) / L; res += (abs(Y) + L - 1) / L; cout << res << '\n'; return 0; }