SHARE
TWEET

MJAU

a guest Nov 12th, 2019 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <stdio.h>
  2. int main()
  3. {
  4.     int n,m,i,h,g,countc=0, countpc=0;
  5.     scanf("%d %d", &n, &m);
  6.     for(i=n; i<=m; i++)
  7.     {
  8.         g=i;
  9.         while(g!=0)
  10.         {
  11.             g=g/10;
  12.             countc++;
  13.         }
  14.         h=i;
  15.         while(h>0)
  16.             {
  17.             if((h%10)%2==0)
  18.             {countpc++;
  19.             h=h/10;}
  20.         }
  21.         if(countc==countpc)
  22.            {
  23.                break;
  24.            }
  25.         else
  26.             printf("NSN");
  27.  
  28.     }
  29.     return 0;
  30.    
  31. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top