def tf(tokens):
    """ Compute TF
    Args:
        tokens (list of str): input list of tokens from tokenize
    Returns:
        dictionary: a dictionary of tokens to its TF values
    """
    d = {}
    s = len(tokens)
    for w in tokens:
        if w not in d:
            d[w] = 1.00/s
        else: 
            d[w] += 1.00/s
    
    return d