How did human beings develop altruism?
This is not the real answer, just a conjecture
Human beings did not develop altruism.
Instead, human beings evolved, and developed societal darwinism, meaning the societies with altruism did better than societies without altruism. Basically, when humans sacrificed for the "greater good" and were kind, then the society as a whole became better, more welcoming, and more efficient, and thus survived.
Perhaps it is similar to the development of social interaction, communities, and collaboration: when people help each other out, everyone benefits.