def _lc(filename: str) -> int:
    """
    Helper function to count the number of lines in a file.

    :param filename: name of the file to be read -- assumed to be plain text.

    :returns: count of the number of lines in file 
    """
    c = None
    with open(filename,'r') as fh:
        c = 0
        for line in fh:
            c += 1
    return c