C Program to write Lottery Logic using ‘if’ statement.
How does this program work?
- This code helps to how to write Lottery Program using ‘if’ statement.
Here is the code
main(void)
{
int l;
printf("Welcome To Kalamandir \n");
printf("Enter Your Lucky Coupon Number:\n");
scanf("%d",&l);
if(l==1917||l==3036||l==0321)
{
printf("You Won A Car");
}
else if(l==6964||l==7075||l==8097)
{
printf("You Won A Bike");
}
else if(l==6685||l==2048||l==9989)
{
printf("You Won A Gift Coupon");
}
else
{
printf("You Are Not A Winner \n");
printf("Better Luck Next TIme");
}
}