<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def cheat(num):
 """View the answer to a problem."""

    # Define solution before echoing in case solution does not exist
    solution = click.style(Problem(num).solution, bold=True)
    click.confirm("View answer to problem %i?" % num, abort=True)
    click.echo("The answer to problem {} is {}.".format(num, solution))