It hasn’t been done randomly or just for fun, it has a very distinct and purposeful reason behind it.
The current format of the keyboard was devised long back in 1870’s by a gentleman namedChristopher Sholes. Though, it definitely was not the first format to come up, it didn’t takemuch time to switch to this one. Starting with lexicographic order i.e. A-B-C-D-E-F, after various trials and errors and taking hundreds of cases, Christopher Sholes gradually reached the Q-W-E-R-T-Y.
When the typewriter was invented, it used a metal bar to hold the character alphabets and the other end of the bar was attached to a linkage carrying a carriage with the coated ink.
Christopher Sholes found a way out. He proposed that the letters of frequently used letter pairs should be in different rows. For example, ‘C-H’, ‘S-T’, ’T-H’, ‘W-H’ and more.
He also formulated that to speed up the typing process, there has to be a regular alternationbetween two hands. So observing thousands of words, he placed the letters in way that most words would make use of both hands.
He also observed that almost every word in the dictionary carries a vowel.
According to him, the most frequently used vowel was ‘A’ and the most frequently used letter (non-vowel) was ‘S’. So he placed ‘A’ and ‘S’ together and chose to keep less common letters like ‘Q’, ‘W’, ‘Z’, ‘X’, ‘C’ around these.
This was complemented by placing fairly common letters like ‘M’, ‘N’, ‘L’, ‘K’, ‘O’, ‘P’ at right extremes to create a perfect alternation between both the hands.