<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def count_lines(fname, mode='rU'):
    '''Count the number of lines in a file

    Only faster way would be to utilize multiple processor cores to perform parallel reads.
    http://stackoverflow.com/q/845058/623735
    '''

    with open(fname, mode) as f:
        for i, l in enumerate(f):
            pass
    return i + 1