week3 output results in respective functions