Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <cmath>
- using namespace std;
- int main() {
- cout << "yea";
- int a = 32, b = 33, c;
- bool exit_loop = false;
- while (!exit_loop) {
- c = 100;
- for (int i = 100; i > b; i--) {
- c = i;
- if (pow(a,2) + pow(c,2) == 2 * pow(b, 2)) {
- cout << b;
- exit_loop = true;
- break;
- }
- }
- b++;
- }
- cout << "yea";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement