The Kobayashi Maru is a test in the fictional Star Trek universe.
It is a Starfleet training exercise designed to test the character of cadets in the command track at Starfleet Academy. The Kobayashi Maru test was first depicted in the opening scene of the film Star Trek II: The Wrath of Khan and also appears in the 2009 film Star Trek. Screenwriter Jack B. Sowards is credited with inventing the test, naming it after a friend whose last name was Kobayashi. The test is sometimes mentioned or depicted in ancillary Star Trek media, including novels and video games. The test's name is occasionally used among Star Trek fans or those familiar with the series to describe a no-win scenario, or a solution that involves redefining the problem and testing one's character.
The notional primary goal of the exercise is to rescue the civilian vessel Kobayashi Maru in a simulated battle with the Klingons. The disabled ship is located in the Klingon Neutral Zone, and any Starfleet ship entering the zone would cause an interstellar incident. The approaching cadet crew must decide whether to attempt rescue of the Kobayashi Maru crew – endangering their own ship and lives – or leave the Kobayashi Maru to certain destruction. If the cadet chooses to attempt rescue, the simulation is designed to guarantee that the ship is destroyed with the loss of all crew members. --Wiki