Home   Easy-Code    Forum  Updater 
Twitter Facebook



Program to print the triangle using c ten

Critics Rating:

Users Rating:



      /* PROGRAM TO PRINT THE TRIANGLE */



#include <stdio.h>

main()

{

int n,i,j,k=5;

clrscr();

printf("ENTER THE NUMVER OF LINES ");

scanf("%d",&n);

for(i=n;i>0;i--)

{

for(j=0;j
   printf(" ");

for(j=1;j<=i;j++)

   printf("%2d",i);

k++;

printf("\n");

}

getch();

}

Courtesy, Source, References & Regards: Kishore AVGK

While using this site, you agree to have read and accepted our terms of use and privacy policy.
Copyright@2009-2011 by KuGuNi.com. All Rights Reserved.