Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <stdio.h>
- #include <math.h>
- #include <iomanip>
- #include <conio.h>
- #include <cmath>
- using namespace std;
- int main()
- {
- long double q, b, p, pi;
- pi=3.14159265359;
- cin >> q;
- cin >> b;
- if (b>q){
- p=pi*(q/2)*(q/2);
- }else{
- p=pi*(b/2)*(b/2);
- }
- cout <<fixed<<setprecision(2)<< p <<endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement