Generate all possible n-grams