結果
問題 | No.98 円を描こう |
ユーザー |
![]() |
提出日時 | 2014-12-21 00:27:06 |
言語 | C++11 (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 5,000 ms |
コード長 | 188 bytes |
コンパイル時間 | 169 ms |
コンパイル使用メモリ | 31,616 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-06-12 02:48:24 |
合計ジャッジ時間 | 631 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 6 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:8:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 8 | scanf( "%d%d", &x, &y ); | ~~~~~^~~~~~~~~~~~~~~~~~
ソースコード
#include<cstdio>#include<cmath>#define rep(i,a) for(int i=0;i<(a);++i)int main(){int x, y;scanf( "%d%d", &x, &y );printf( "%d\n", (int)floor(2*sqrt(x*x+y*y))+1 );return 0;}