SHARE
TWEET

Untitled

a guest Mar 24th, 2019 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include<stdio.h>
  2. int main()
  3. {
  4.     int x,y;
  5.     printf("enter the two number:");
  6.     scanf("%d%d",&x,&y);
  7.     if(y> 0)
  8.     {
  9.         while(y!=0)
  10.         {
  11.             x++;
  12.             y--;
  13.  
  14.         }
  15.  
  16.  
  17.  
  18.  
  19.     }
  20.  
  21.  
  22.  else if(y< 0)
  23.         {
  24.             while(y!=0)
  25.             {
  26.                 x--;
  27.             y++;
  28.             }
  29.  
  30.  
  31.  
  32.         }
  33.  
  34.  
  35. printf("sum of value is %d",x);
  36.  
  37.  
  38.  
  39.  
  40.  
  41.     return 0;
  42. }
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