Friday, October 4, 2013

Program to determine the value of a variable num2 depending on num1



#include<stdio.h>
#include<conio.h>

int main( )
{
 int num1,num2;
 clrscr( );
 printf("\n Enter the value of num1::");
 scanf("%d",&num1);
 num2=num1>10? 0:1;
 printf("\n The value of num2 is::%d",num2);
 getch();
 return 0;
}

No comments:

Post a Comment