added cases for all letters and accounted for repeats