def frequencies(l):
    """
    Return number of times each item appears in the list.
    """
    result = {}
    for item in l:
        if not item in result:
            result[item] = 0
        result[item] += 1
    return result
