Programme:
Code:
#include<stdio.h>
#include<conio.h>
main( )                                                                        
{  int i,j;                                                                   
   clrscr( );                                                                  
   i=1;                                                                       
   while(i<=5)                                                                
   {                                                                          
      printf("   ");                                                          
      j=1;                                                                    
      while(j<=i)                                                             
       {                                                                      
         printf(" * ");                                                       
         j++;                                                                 
       }                                                                      
       printf("\n");                                                          
       i++;                                                                   
   }                                                                          
    getch( );                                                                  
}
O/P:
Code:
    *
    *  *
    *  *  *
    *  *  *  *
    *  *  *  *  *

Last edited by shabbir; 16Aug2009 at 09:55.. Reason: Code blocks