結果
問題 | No.48 ロボットの操縦 |
ユーザー |
|
提出日時 | 2019-03-31 21:00:09 |
言語 | Go (1.23.4) |
結果 |
WA
|
実行時間 | - |
コード長 | 465 bytes |
コンパイル時間 | 11,155 ms |
コンパイル使用メモリ | 223,436 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-22 10:10:02 |
合計ジャッジ時間 | 12,060 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 24 WA * 1 |
ソースコード
package mainimport ("fmt""math")func main(){var x, y, l float64var cnt intfmt.Scan(&x)fmt.Scan(&y)fmt.Scan(&l)if y < 0 {if x != 0 {cnt += 2} else if x == 0 {cnt += 3}} else if y == 0 && x != 0 {cnt++} else if x != 0 {cnt++}cnt += int(math.Ceil(math.Abs(x) / l))cnt += int(math.Ceil(math.Abs(y) / l))fmt.Println(cnt)}