Advertisement
Guest User

Untitled

a guest
Nov 22nd, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. #include <iostream>
  2. #include <cmath>
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. double x,y,h,S,P,a;
  8. cout<<"Vuvedi t.A:";
  9. cin>>x>>y;
  10. h=3*sqrt((x*x)+(y*y))/2;
  11. a=h/sqrt(3);
  12. P=a*3*2;
  13. S=a*2*h/2;
  14. cout<<"P="<<P<<endl<<"S="<<S;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement