Code:
#include<stdio.h>
int main ()
{
int i,j;

for(i=1;i<=5;i++)  {
  for(j=1;j<=i;j++)
    printf("%i",i);
  printf("\n");
}

return 0;

}
The output is
1
22
333
4444
55555

this is the "for" method, how do i convert it into while and do..while format? i just still noob in programming , any expert help me out pls? thx

Last edited by shabbir; 12Dec2007 at 22:22.. Reason: Code block