WAP to print series from 20 to 1
#include
void main ()
{
int a;
clrscr ();
a=20;
while (a>=1)
{
printf ("\n%d",a);
a--;
}
getch ();
}
Free C programs with output, C++ (C plus plus), programs c programming language, object oriented programming, c programs codes, c program shortcuts, history of c programming language, c programming compilers
WAP to print series from 20 to 1
#include
void main ()
{
int a;
clrscr ();
a=20;
while (a>=1)
{
printf ("\n%d",a);
a--;
}
getch ();
}
void main ()
{
int a;
clrscr ();
a=1;
while (a<=20)
{
if (a%2==1)
printf ("\n%d",a);
a++;
}
getch ();
}
#include
void main ()
{
int no,r,res,temp=0;
clrscr ();
printf ("Enter Number: ");
scanf ("%d",&no);
r=res=0;
temp=no;
while (no>0)
{
r=no%10;
no=no/10;
res=(res*10)+r;
}
if (temp==res)
printf("Number is Palandrom");
else
printf("Number is not Palandrom");
getch ();
}