Saturday, 10 December 2011

a program to to print a star by define spaces enter b user in c

#include
#include
main()
{
int i,sp;
clrscr();
printf("Enter Number of Spaces:-");
scanf("%d",&sp);
for(i=1;i<=sp;i++)
printf(" ");
printf("*");
getch();
}
Enter Number of spaces:- 10

No comments:

Post a Comment