def extrep_frac(lst1, lst2):
    """Returns the fraction of items in lst1 that are in lst2"""
    if len(lst1) == 0:
        return 0
    num_rep = len([x for x in lst1 if x in lst2])
    return num_rep / len(lst1)