def n_gram(token_list, n, c = " "):
    """
    given a token list, return the n-gram version of it
    """
    ret = []
    for l in range(1, n+1):
        for i in range(len(token_list)):
            if i + l <= len(token_list):
                ret.append(c.join(token_list[i:i+l]))
    return ret