0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-12-24 03:31:59 +00:00

B2015 计算并联电阻的阻值

R53273658
This commit is contained in:
Baoshuo Ren 2021-07-16 10:57:48 +08:00 committed by Baoshuo Ren
parent d4930597c4
commit 3bf4920268
Signed by: baoshuo
GPG Key ID: 70F90A673FB1AB68

View File

@ -0,0 +1,10 @@
#include <bits/stdc++.h>
using namespace std;
int main() {
double r1, r2;
cin >> r1 >> r2;
cout << fixed << setprecision(2) << 1 / (1 / r1 + 1 / r2) << endl;
return 0;
}