結果
問題 |
No.98 円を描こう
|
ユーザー |
![]() |
提出日時 | 2015-05-14 05:43:04 |
言語 | Go (1.23.4) |
結果 |
WA
|
実行時間 | - |
コード長 | 261 bytes |
コンパイル時間 | 10,824 ms |
コンパイル使用メモリ | 233,132 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-10-10 04:25:02 |
合計ジャッジ時間 | 10,816 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 4 WA * 2 |
ソースコード
package main import ( "fmt" "math" ) func main() { var x, y int fmt.Scan(&x, &y) z := math.Sqrt(float64(x*x+y*y)) if z == 0{ fmt.Println("1") } else if z == float64(int64(z)){ fmt.Println(math.Ceil(z)*2+1) }else{ fmt.Println(math.Ceil(z)*2) } }