Corrected recursion

output from 0 to n in recursion