結果
問題 |
No.89 どんどんドーナツどーんといこう!
|
ユーザー |
|
提出日時 | 2024-09-27 18:21:00 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 28 ms / 5,000 ms |
コード長 | 452 bytes |
コンパイル時間 | 1,936 ms |
コンパイル使用メモリ | 191,544 KB |
最終ジャッジ日時 | 2025-02-24 13:28:12 |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 9 |
ソースコード
#include <bits/stdc++.h> using namespace std; using ll = long long; #define rep(i, s, e) for (int i = (int)s; i < (int)e; i++) double pi = 3.141592653589793238; int main() { cin.tie(nullptr); cout << fixed << setprecision(15); double C, Rin, Rout; cin >> C >> Rin >> Rout; double r = (Rin + Rout) / 2; double rr = (Rout - Rin) / 2; double ans = C * rr * rr * pi * 2 * pi * r; cout << ans << '\n'; }