"Detective" Chang investigates a noir mystery in his mind. Later, the gang gives Dean Pelton a hard time for charging students for using the drinking fountain. Professor Kane tells the class that they have to pair up to create a terrarium. Troy immediately objects to being paired up with classmates who might as well be strangers.
The gang tells Professor Kane that they're a study group and simply can't partner with total strangers. Their cries fall on deaf ears, so they decide to scare off their new lab partners. Meanwhile, Chang tells Nunez that he's now a detective. Nunez disregards Chang, but Chang remains determined to be a detective and solve a crime.
The gang begins building their terrariums. Abed and Troy are paired together and realize immediately that they spend too much time together. Stuck in a noir fantasy, Chang reminisces about a long-lost dame and decides a matchbook is a clue. Leading to what, he doesn't know. Later, Troy and Britta imagine what it would be like if they were partnered for the project. Meanwhile, Pierce complains about being with a strange student named Todd.
The group convenes to deal with Todd, the weird guy paired with Pierce. Who will take the bullet and deal with Todd? There seems to be no way to get rid of him. Finally, Abed decides that Jeff should pair with Todd, based on their lack of "appeal." Later, Chang continues investigating a mysterious matchbook. Nunez tells Chang to take some time off. He's clearly losing his mind.
The group members continue debating who should pair with whom. Soon everyone's name-calling and complaining. Chang absentmindedly sets a fire in the cafeteria. He enjoys investigating the mysterious crime, never realizing he's the one who committed it. After listening to all the fighting, Todd snaps. He thought they were all supposed to be friends, but now he thinks they're all toxic.
Students present their terrariums to the class. Professor Kane notices that the entire study group has only managed to put together one terrarium. Professor Kane scolds them. He's especially angry that they traumatized his friend Todd. Nunez finally quits because he thinks Chang might be mentally ill. Dean Pelton tells Chang he's the new head of security.