Gatling came first by about 15 years. There was a poem in the late 1800's to the effect that the difference between the British Army in Africa and the Natives was that "we had got the Maxim and they had not".
An interesting historical note, The 4 competitors for the American machine gun market in the late 1800's (Maxim was in Europe though he was FROM Me.) Gatling, Nordenfeldt, Hotchkis,and Browning, were ALL manufactured at the Colt plant in Hartford Ct.
Hotchkis moved to Europe, Gatling and Nordenfeldt eventually opened their own factories across the street from each other in Hartford.
AK is not a "battle rifle". It is an "ASSAULT RIFLE" (AKA Sturm Gewehr) select fire , carbine length, intermediate cartridge.