The dark truth about keeping chickens and many other poultry is that they hatch in an approximately 1:1 male:female ratio, but can't be kept in that ratio without severe conflict and stress. Thus, hatching chickens to keep for egg-laying requires killing most of the male chicks. So yes, you have to kill chickens to eat eggs.
Same for dairy cattle: males are redundant. My grandfather was an AI pioneer in the UK in the 1940s. AI being artificial insemination of dairy cattle....
We put the redundant roosters in the woods, let nature do the killing for us. They didn't last one night.
The "severe conflict and stress" part may be hard to understand for the cityfolk; you have to kill chickens to eat eggs, or else they will do it.