Imagine that on the way to work, you notice a child falling into a pond and drowning. Of course, you jump into the pond, pull out the child and save a life. Afterwards, you feel quite good about yourself.

Later that day, you go to a cafe, and while chatting with the waitress about what cake she would recommend, you mention your heroic deed. Are you now justified to grope her or to expose your genitals?

This may sound absurd. However, assuming that their donations to children’s charities actually saved lives, that was the question some of the attendees of the Presidents Club Charity Dinner faced. Thanks to undercover reporting from the Financial Times, it has emerged that some of them decided to sexually harass the hostesses.

How could anyone think that this horrifying behaviour is justified just because they did something good before – such as give money to charity? To explain the thinking behind the incident, it is helpful to look at the Presidents Club through the lens of moral philosophy. It offers lessons on how not to behave like this.

Grouping actions

Let’s pretend that we are participants of that fundraiser, trying to find a moral justification for our decision to do badly. In our search, we could turn to our good deeds. We saved lives by bidding at the charity auction, so would not the good we did outweigh the bad?

The theory classically associated with this thinking is utilitarianism, which asks you to act to promote the most happiness for the greatest number of people. Sometimes, this requires you to do something bad to bring about the greatest good. For example, you may need to lie to a racist mob about the location of your black neighbours to save their lives.

But this would not apply for the charity gala. In the case of the racist mob, lying is necessary to save your neighbours. Without the bad act, you would not be able to do the good deed. But whether you grope the waitress or not is absolutely independent from you saving a life. Both actions could happen without the other – you do not need to grope anyone to donate.

So, utilitarianism does not provide us with a justification, but rather teaches us our first lesson: do not group actions together that can be evaluated independently.

Moral offsetting

Maybe you think that your good deed balances out your bad behaviour. This is an idea known as “moral offsetting”, where you do something good to offset the harms you did. So, if you give to children’s hospitals, does that offset harassment?

It does not. Moral offsetting should not be understood as buying licences for behaving badly. Normally, offsetting is applied to bad behaviour that has already happened. In this case, the good deed happened first, and who would want to “offset” a virtuous donation?

Desert theories are also applicable. The idea here is that because you did one action, you deserve some kind of payoff – you get your just deserts. For example, because you worked and studied hard, you deserve a good mark in your exam.

This could explain the behaviour at the fundraiser: some rich people donate their money to children’s hospitals and therefore think they deserve some kind of payoff – here provided by the organiser in the form of lightly dressed young women. It looks likely that some of the men at the dinner felt entitled to treat the hostesses as a reward for their altruistic donations.

However, desert theories normally do not allow for a bad action as a payoff: your good deed should entitle you to some appreciation, but does not licence you to hurt others.

To wrong others is not valuable, and therefore desert theory cannot justify bad actions based on good deeds. So here is a second lesson: expecting a reward for your altruistic behaviour undermines the altruistic nature of your action. If you donate and expect some form of appreciation, you do not give for altruistic reasons – you act out of self-interest.

But desert theory is still helpful for us to understand why some of the men at the fundraising dinner may have felt entitled to behave badly. Because some felt they deserved a reward, they lowered the standards for their own behaviour to the point of groping. This mechanism is called moral licensing.

Hard questions

A possible reason why some people engage in such thinking, even if it leads them to obviously wrong behaviour, is because thinking about morality is hard. Our brains are lazy, and because hard questions require cognitive effort, we often replace them with an easier question.

The psychologist Daniel Kahnemann describes this as substitution bias: the question how much you should donate against global poverty is hard, for example. It is easier to replace it with the question of how you feel when you think about starving children and then give according to how you feel.

Whether an act is right or wrong is a hard question. People will often substitute this question with whether they feel entitled to do it. Because some of the men at the fundraiser did not want to think about the wrongness of groping, they may have substituted it with a feeling of entitlement. And here is a final lesson: if you feel entitled to do something, that does not mean that it is right to do it. You may be answering the wrong question.

So, a good deed does not justify a bad act. And of course, it is absolutely not okay to grope women because you donated large sums of money to charity. To help avoid this way of thinking in the future, we should not group together independent actions, nor expect rewards for altruistic deeds. And we should remember what questions to ask ourselves – and think harder about right and wrong.

Anh Quan Nguyen is a PhD Candidate at the University of St Andrews.

This article first appeared on The Conversation.