結果
問題 | No.98 円を描こう |
ユーザー |
|
提出日時 | 2021-04-12 02:50:00 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 349 bytes |
コンパイル時間 | 2,034 ms |
コンパイル使用メモリ | 194,752 KB |
最終ジャッジ日時 | 2025-01-20 16:14:23 |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 6 |
ソースコード
#include<bits/stdc++.h> using namespace std; using ll = long long; bool is_integer(double x){ return floor(x) == x; } int main(){ double xp,yp; cin >> xp >> yp; double ans = 0; double dist = sqrt(xp*xp + yp*yp); dist = 2*dist + 1; dist = floor(dist); ans = dist; cout << ans << endl; }