proverb

Two blacks do not make a white.

wrong

expresses that

If someone does something wrong, doesn't mean that we are excused for doing the same wrong.

Related

similar

Also

Two wrongs do not make a right