Look at what it actually prints, and ask yourself a question:
1
1 1
1 1 1
1 1 1 1
1 1 1 1 1
"Why does it print that?"
The answer is: because "1" is what
c
contains each time round the loop.
So ... why? Simple: your assignment of
c
in the outer loop is irrelevant because you always overwrite it in the inner loop ... Think about the sequence you need to print and ask yourself another question: "Why do I need
c
at all?"