The introduction to one of the versions of Left Hand of Darkness is one of my favorite texts about Science Fiction: http://theliterarylink.com/leguinintro.html
https://en.wikipedia.org/wiki/The_Ones_Who_Walk_Away_from_Om...
The EarthSea Trilogy has stuck with me too.
Short read and available online:https://www.utilitarianism.com/nu/omelas.pdf
But then I wondered "Why did they walk away? Why not comfort the child and end it?"
In the story she says a single kind word to the child would end it. I can understand living there, but I don't understand walking away.
By walking away you are not helping the child. So what does it matter that you are not benefiting?