Utilitarianism is an ethical philosophy, which states that the best course of action is the one that creates for the greatest amount of happiness for the greatest number of people. From this perspective, what only matters is the outcome of happiness, not so much the means. John Stuart Mill is perhaps the best known person who espouses this view. Let me give two examples to underline the dynamics of a utilitarian view.
Within a utilitarian framework, the sacrifice of a person for the good of a group would be a proper application. The number of people who would be saved outnumber the one who would be sacrificed.
To give a more concrete example, if there was a sinking ship and only one life raft, which did not have enough room, the captain or leader of the ship should fill that boat up with the proper number of people and let it go with the rest of the people to drown. The assumption is that a few alive is better than all dead.