#Java, 123 bytes interface y{static void main(String[]s){int a=new Integer(s[0]),c=0,i;while(++c<=a){i=c;while(i>0)System.out.print(i--);}}} Takes input as command line argument. Ungolfed with comments: interface y{ static void main(String[] s) { int a = new Integer(s[0]), // Input number c = 0, // Counter 1 i; // Counter 2 while (++c <= a) { // Increment counter 1. Until counter 1 is less or equal to input i = c; // Counter 2 = counter 1 while (i > 0) // Until counter 2 is more than 0 System.out.print(i--); // Output counter 2 and decrement it } } }