c program to print given number pattern

Write a c program to print given number pattern
111111
22222
3333
222
11
0

#include<stdio.h>
int main()
{
  int k,j;
  for(k=1;k<=6;k++)
  {
    for(j=6;j>=k;j--)
    {
      if(k<=3)
        printf("%d",k);
      else
        printf("%d",6-k);
    }
    printf("\n");
  }
}
Copyright © C Program | Java | OpenGL Programming | Hadoop at Computaholics