Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <math.h>
- using namespace std;
- int main()
- {
- int figura=1;
- int a=2,b=3;
- int pole, obwod;
- cout << "dlugosc pierwszego boku wynosi: "<<endl;
- cout << "dlugosc drugiego boku wynosi: "<<endl;
- switch (1)
- {
- case 1:
- if (a==b)
- {
- pole=a*a;
- obwod=(2*a)+(2*b);
- cout << "Pole jest równe " << pole << "a obwod jest rowny " << obwod<<endl;
- else
- {
- pole=a*b;
- obwod=(2*a+2*b);
- cout << "Pole jest równe " << pole << "a obwod jest rowny " << obwod<<endl;
- }
- break;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement