This is the 13146th most frequent Russian word.
меняя
"Меняя" means "changing" or "while changing."
Here 'меняя' is a verbal adverb derived from 'менять', indicating the action of replacing or swapping occurring simultaneously with noticing the brightness.
Меняя старую лампочку на новую, он сразу заметил, как стало светло.
By changing the old bulb to a new one, he immediately noticed how bright it became.
In this sentence, 'меняя' represents the action of trading items, modifying the walking on the market.
Девушка прошлась по рынку, меняя один товар на другой.
The girl walked through the market, exchanging one item for another.
The word 'меняя' here indicates the continuous action of changing the topic during the conversation.