The Kobiyashi Maru scenario' is a test given to command-track cadets. It is a test of character to see what a potential captain would do in a no-win scenario. The cadet patrols the Klingon Neutral Zone in a simulated starship, the USS Horizon. The ship receives a distress call from a neutronic fuel carrier, the Koiyashi Maru, from inside the Neutral Zone. If the cadet attempts to aid the Maru, three Klingon cruisers attack. The computer ensures that it is impossible for the cadet to save both the Marus passengers and their own ship.
James T. Kirk was famously the first cadet to beat the scenario in the 2250s. Before his third attempt, kirk reprogrammed the scenario, eliminating the parts of the program that made it impossible to win. He then tricked the attacking ships into warping away, giving him time to evacuate the Maru. Admiral Jublik and Zheng assigned Kirk ninty-nine demerits, just short of the expulsion limit. (SNW VII: "A Test of Character")
- Kobayashi Maru scenario at Memory Alpha.