C Pattern using word "Programming" & Unformatted Function


#include<stdio.h>

int main()
{
 int i,j;
 char str[] = "Programming";
 clrscr();
 for(i=0;i< 6;i++)
 {
  for(j=i;j< 11-i;j++)
  {
   putchar(str[j]);
  }
  putchar('\n');
 }

 return(0);
}

Output

Programming
rogrammin
ogrammi
gramm
ram
a