Also a possibility that TOS was trying to emulate the stellar types of O-B-A-F-G-K-M with a similar classification for planets.
Why O-B-A-F-G-K-M? Why that order? Why seven letters?
What does each stand for?
Originally, in the 1860s when spectroscopy was first used to distinguish stars into different spectral types, they were labeled alphabetically from A to P in order of the strength of their hydrogen Balmer lines. Later, once we gained more understanding of the hydrogen atom and the nature of its emissions, it was determined that different factors affected the strength of the hydrogen lines and that it wasn't a straight increase with temperature -- cooler stars didn't have enough energy to boost the H atoms' electrons out of the ground state, and hotter stars had enough energy to ionize the atoms altogether so there were no electrons to jump and produce Balmer lines. So the strongest lines were from stars around 10,000 K, dropping off in either direction, and that meant the alphabetical classification based on Balmer line strength didn't represent a meaningful temperature progression. Early in the 20th century, Harvard astronomers revised the classification system, dropping redundant categories and reordering them by temperature, leaving OBAFGKM from hottest to coolest.