Advertisement
Guest User

Untitled

a guest
Jan 19th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7.  
  8. int x, y, z;
  9. cout << "Podaj liczbe x:";
  10. cin >> x;
  11. cout << "Podaj liczbe y:";
  12. cin >> y;
  13. cout << "Podaj liczbe z:";
  14. cin >> z;
  15. z=z*z;
  16. for(int i=x; i<=y; i++)
  17. {
  18. if (i%z!=0)
  19. {
  20. cout << i << ", ";
  21. }
  22. }
  23. return 0;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement