Print number in reverse order using 'c'
(Click on read more)
#include<stdio.h>
#include<conio.h>
void main()
{
int i,n;
clrscr();
printf("Enter the number from you want to print:");
scanf("%d",&n);
for(i=n;i>=1;i--)
{
printf("\n%d",i);
}
getch();
}
OUTPUT:
Enter the number from you want to print:10
10
9
8
7
6
5
4
3
2
1
Comments
Post a Comment