How to teach an artificial brain to understand right and wrong