Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //29 pusl. 3 uzd.
- #include <iomanip>
- #include <iostream>
- #include <cmath>
- using namespace std;
- int main()
- {
- int x, x1, x2, y1, y2;
- cout << "Intervalo pradzia: "; cin >> x1;
- cout << "Intervalo pabaiga: "; cin >> x2;
- x=x1;
- for (x; x <= x2; x++) {
- y1 = x * 2 + 2;
- y2 = x * 3 + 1;
- cout << setw(4) << fixed << x << setw(4) << fixed << y1 << setw(4) << fixed << y2 << " "; if (y1==y2) cout << "Susikerta\n"; else cout << "***\n";
- };
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement