"Imagine a universe consisting of one sentient being only, who falsely believes that there are other sentient beings and that they are undergoing exquisite torment. So far from being distressed by the thought, he takes a great delight in these imagined sufferings. Is this better or worse than a universe containing no sentient beings at all? Is it worse, again, than a universe containing only one sentient being with the same beliefs as before but who sorrows at the imagined tortures of his fellow creatures?"
-An outline of a system of utilitarian ethics, J. J. C. Smart
Spoiler (sort of) - I'm going to explain the reasoning of the author, but if you want to think through your own ideas first, you might wait to read this so it doesn't bias you.
Overall, the scenario is supposed to help the reader to think about whether they believe in a set of absolute good and evil states, or whether they believe in the Utilitarian idea that the best state is the one in which there is the most happiness for the most people. Smart (a utilitarian) argues that the universe containing the deluded sadist is the preferable one. "Since he is happy and since there is no other sentient being, what harm can he do?" Smart also argues that people's repugnance to the sadist exists because in our universe sadists invariably do harm, therefore people are conditioned to dislike them. He believes that "when we call something 'bad' we mean indifferently to express a dislike for it in itself or to express a dislike for what it leads to."