![]() |
|
|
+ Search |
![]()
|
Apr 14th, 2005 02:30
Ankit Sharma, sumit sood,
Following is the solution for this:
You can change the input mechanism of this program, i hav taken the
hardcoded string...
#include <string.h>
main()
{
char str[]="space";
char *ptr=str;
int i=0,j=0;
while(i<=strlen(str))
{
printf("%s",(ptr+i));
while(j<i)
putchar(*(ptr+j++));
i++;
j=0;
printf("\n");
}
}