<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def top_hits(hits, num, column, reverse):
 """ get top hits after sorting by column number """

    hits.sort(key = itemgetter(column), reverse = reverse)
    for hit in hits[0:num]:
        yield hit