Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- #include <math.h>
- using namespace std;
- int main()
- {
- float x,y,d;
- cout << "Nikola Krudulj IV3" << endl;
- cout << "X: ";
- cin >> x;
- cout << "Y: ";
- cin >> y;
- d = sqrt(pow(x, 2) + pow(y, 2));
- cout << setw(7) << setprecision(3) << d;
- return 0;
- }
Add Comment
Please, Sign In to add comment