Printing Patterns Using Loops In C Hackerrank Solution