Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int x;
- float P=0,OBW=0;
- do
- {
- cout << "Podaj dlugosc promienia kola" << endl;
- cin >> x;
- } while (x <= 0);
- P = 3.14 * x;
- OBW = 3.14 * (2*x);
- cout << "Obwod kola wynosi: " << OBW << endl;
- cout << "Pole kola wynosi: " << P << endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement