Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main(){
- int x, y, num, cifra;
- int i=0, flag;
- scanf("%d%d", &x, &y);
- for(i=x;i<=y;i++){
- num=i;
- flag=0;
- while(num){
- cifra=num%10;
- if(cifra==1||cifra==3||cifra==5||cifra==7||cifra==9){
- flag = 0;
- break;
- }
- flag=1;
- num/=10;
- }
- if(flag){
- printf("%d",i);
- return 0;
- }
- }
- printf("NE");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement