Fix 1-09's solution

My initial solution tried to simplify the conditions for outputting a
space. You really do need two 'if's in there.