Problem:
Q. Write a program that print a table of any given number by checking the condition if the given is not equal to zero then generate a table. used not operator.
Program:
#include<stdio.h>
#include<conio.h>
int main ()
not operator in c++ |
{
int
a,b,i;
printf("enter
a number");
scanf("%d",&a);
if(!(a==0))
{
for(i=1;i<=10;i=i+1)
{
b=a*i;
printf("\n%d
x%d =%d",a,i,b);
}
}
getch();
}
what is not operator. see detail
0 comments:
Post a Comment
Please do not enter any spam link in the comment box