Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- int startNum, finalNum;
- cin >> startNum >> finalNum;
- for (int i = startNum; i <= finalNum; i++) {
- for (int k = startNum; k <= finalNum; k++) {
- for (int j = startNum; j <= finalNum; j++) {
- for (int x = startNum; x <= finalNum; x++) {
- if ((i % 2 == 0 && x % 2 == 1 || i % 2 == 1 && x % 2 == 0)
- && i > x && (k + j) % 2 == 0) {
- cout << i << k << j << x << " ";
- }
- }
- }
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement