What do you call the act of moving as a group one at a time with the last person going in front of the first person and on and on? I think the word leapfroging is used, but it involves jumping over a person, is there a more general way of referring to that? For example, what if the people are just walking instead of jumping over one another?
The word "leapfrogging" can be used to describe a situation where the last person in line goes to the front of the line without actually jumping over anyone, and then the last person remaining in line goes to the front, and so on. That would be a metaphoric use of "leapfrog". One might also say:
The people in the line move in succession from the rear of the line to the front.
This is a somewhat awkward way of moving a group, and so rare. Therefore there is no more specific word that I know of for this procedure. '
Leapfrogging, as you state, can by extension describe that motion (horizontally) in a line. It can even be used, by extension, to describe development of industry or technology: as an older monopoly or technique stagnates, new ones leapfrog past the old.
See, also, the vaguely similar concept of musical chairs.