Alongside most of these answers that clarify that the vast majority of the time they did not.
Officers that stood out and could be recognized on the front lines stopped being a thing after WW1.
Reason: during WW1 there were a lot of officers that died because if you can recognize your officer at a glance, then the enemy can too, and snipers exist now.
Latest Answers