simplified the function definition output