Removed printleaves method and just print straight in loop.