結果

問題 No.948 Bomb vs Dush
ユーザー kotatsugame
提出日時 2019-12-19 01:15:52
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 225 bytes
コンパイル時間 613 ms
コンパイル使用メモリ 73,716 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-07-06 23:14:49
合計ジャッジ時間 1,840 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 38
権限があれば一括ダウンロードができます
コンパイルメッセージ
main.cpp:6:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    6 | main()
      | ^~~~

ソースコード

diff #

#include<iostream>
#include<cmath>
#include<iomanip>
using namespace std;
double r,R;
main()
{
	cin>>r>>R;
	double theta=2*asin(r/R);
	cout<<fixed<<setprecision(16)<<2*M_PI-theta<<endl<<4*r*R*(M_PI-theta/2)+M_PI*r*r<<endl;
}
0