SHARE
TWEET

Untitled

a guest Jun 24th, 2019 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include<iostream>
  2.  
  3. using namespace std;
  4.  
  5. int a,b,i;
  6.  
  7. int main()
  8. {
  9.     do
  10.     {
  11.         cout<<"a= ";cin>>a;
  12.         cout<<"b= ";cin>>b;
  13.         if(a%2==1)
  14.             a++;
  15.         for(i=a; i<=b; i=i+2)
  16.         {
  17.             cout<<i<<" ";
  18.         }
  19.         cout<<endl;
  20.     }while(a<=b);
  21.     return 0;
  22. }
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