N-grams are N-character slices of a string. These can include any character present in a word, but, for the purposes of language recognition, are often restricted to characters found next to each other in a word and include blanks before and after the word.
For example, the word GRAM would have the following N-grams:
- Bigrams (N = 2): _G, GR, RA, AM, M_
- Trigrams (N = 3):   _GR, GRA, RAM, AM_, M__
- Quadrigrams (N = 4): _GRA, GRAM, RAM_, AM__, M___