Ben is an average kid, born "clear," meaning without pre-birth "optimizations" that make people smarter and emotionally well-balanced — "perfect." Surrounded by others who were optimized, he struggles to stay happy. This leads him to seek more "Good," a drug that everyone gets a daily dose of, from the school nurse.
Ben's parents find out that Ben takes extra doses of "Good" and they restrict his access to it. Ben is upset by this. Later that day, a social outsider named Leslie invites Ben to her house to celebrate his birthday.
When Ben goes to Leslie's house, he is appalled by the surroundings, as Leslie lives in a less well-off part of town. Leslie's family feed Ben cake, something he has never had before, and speak about things from before the wars that defined this dystopian society, like comedy. Ben reacts badly to their suggestions that a world without "Good" is possible, and he leaves.
Ben becomes depressed and is kicked out of his friend group, as anything less than exuberance is not socially tolerated. When one of his friends punches him in the face to show him that he is out of the group, Leslie helps Ben to the nurse. The nurse tries to give Ben a shot of "Good" but Ben's sister shows up to enforce Ben's "Good" restriction. Ben accepts the restriction and instead turns to Leslie and tells the joke he learned from Leslie's father, which allows him to show his acceptance of this alternate way of living.