functional print to terminal via two functions