the phrase "survival of the fittest" is a bit unfortunate in that it is readily misunderstood, as is your case here. the fittest doesn't just mean strongest or fastest, which is where the confusion arises. selection is any action by which on average your genes become more common in a population on account of there being more copies made. for natural selection, this usually comes down to breeding success. what you are asking is how can altrustic behaviour favour your breeding success, given that it helps others (including competitors). i'll give you one simple mechanism, but there are others. when animals become more intelligent and social, it helps to cooperate since the team is stronger than the sum of its individual parts. obviously, your team also carry
many of the same genes as you, so altuistic behaviour increases the chances of a gene becoming more common.
now, what if you try and do all the leaning and none of the lifting (thanks tones). well, others in the community will know and you will be shunned. this has been observed in animals other than homo-sapiens.