If so when?
The term is usually used when something inherently unpleasant produces an overall change which is preferable to what would have happened if the unpleasant thing had not been done.
I think there are many occasions in which "... the end justifies the means ...", though many of them are debatable.
Here are two examples:
(a) the Isle of Man had a near zero crime rate, when the normal punishment for crime was "birching". Since birching was abolished, the crime rate has rocketed. Birching is an example of the end justifying the means because virtually nobody suffered the consequences of criminal behaviour while birching was available as a deterent.
(b) The nuclear bombing of Hiroshima & Nagasaki in 1945 - brought World War 2 to a rapid end - thus shortening the war dramatically and almost certainly saving many more innocent lives than were lost by the unprecedented nuclear bombing of civilian areas.
Both debatable, but I have no doubt which side I support: Birching was right while it acted as a deterent; and the extreme bombing of a resolute enemy was right in order to end what was coming to look like a war of attrition. Furthermore the ongoing nuclear deterrent broadly speaking remains a force of good rather than evil, and without it the damp squib of the "Cuban Missile Crisis" could quite easily have been the first (and much more extensive) use of nuclear bombs against civilians - with catastrophic consequences.
-- Best wishes - Majikthise. .
I guess we can talk about 'for the greater good' here. And yet, I still think it is a slippery slope. I think sacrificing certain principles, even if it is one's idea that it is for the greater good, can lead to serious negative consequences (the torture example is one again I have issues with, especially since most of the experts say it is ineffective). I'm sure all leaders who've wreaked havoc on those under their control have managed to convince some that it is all for the greater good. They've probably convinced themselves. After all improving the welfare of the nation is a matter of opinion at the end of the day.
Funnily enough majikthise's examples are the two examples I'd use as the ends not justifying the means. In Uganda they still stick thieves in car tires and set them on fire. Mob justice is well and alive. And yet we still have thieves. What a shock. As for bombing the 'enemy', uhm well I'm guessing the Japanese arent quite so thrilled with what happened. I think there are occasions the ends justify the means, I just can't come up with examples at this moment.
I think we can all agree that sometimes the ends justify the means. If you had a prisoner who planted bombs and torturing them until they told you the locations saved many lives wouldn't the end justify the means even if we all agree that torture itself is wrong? Machavelli believed that the end justifies the means when government actions improve the welfare of the nation. Over the years we have extended this to lots of other things.
Do you mean morally? I'm struggling a bit with the concept. But to me the end only justifies the means if the person at the end is happy with the outcome.
Best wishes - Majikthise.