Exercise solution:
Functions with struct input and struct output