Posted by GoldenRodIt's based on the sound of the following word. If the next word starts with a vowel sound, it's "an". If the next word starts with a consonant sound, it's "a"