Print From n to 1 -
#include <stdio.h>
int main()
{
int n,i;
printf("Enter the number ");
scanf("%d",&n); //Input the number from user
for(i=n ; i>=1 ; i--)
{
printf("%d,",i);
}
return 0;
}
Output -
Enter the number 5
5,4,3,2,1,9
0 Comments