The Practical Joker

"The Practical Joker" is the third episode of the second season of the American animated science fiction television series Star Trek, the 19th episode overall. It first aired in the NBC Saturday morning lineup on September 21, 1974, and was written by American television writers Chuck Menville and Len Janson who together also wrote the first season episode "Once Upon a Planet". The "Rec Room" in this episode is the forerunner of the Holodeck, which plays a significant part in numerous episodes of the subsequent spin-off Star Trek series.

Set in the 23rd century, the series follows the adventures of Captain James T. Kirk (voiced by William Shatner) and the crew of the Starfleet starship Enterprise. In this episode, after the Enterprise passes through an unusual cloud the ship's computer starts playing practical jokes on the crew.

Plot
On stardate 3183.3, the Federation starship Enterprise is attacked by three Romulan D-7-class battlecruisers. Captain Kirk orders the ship into a nearby gaseous energy field to hide, knowing that the Romulans would be unwilling to follow in after them. Sometime later, the crew begin to suffer a series of practical jokes, beginning with glasses leaking and utensils turning to rubber, a uniform tunic for the captain with "Kirk is a Jerk" emblazoned on the back, and a mysterious optical device on the bridge science station which when looked into leaves blackened circles around Science Officer Spock's eyes. Everyone suspects that there is a member of the crew having fun. The jokes become more serious, however, as corridor decks are found covered with ice under a concealing layer of fog. Still thinking that a crew-member is responsible, Chief Medical Officer Dr. McCoy, Lt. Uhura, and Lt. Sulu hope to escape the jokester by hiding out in the ship's Holodeck/Rec Room. No escape is to be found as a quiet stroll in a woodland scene becomes dangerous with the program parameters changing to include a deep pit covered over by branches and leaves, and later a freezing cold blinding snow storm then a hedge maze before they are finally rescued.

Eventually the practical jokester, which turns out to be the Enterprise computer itself (affected by the ship's passage through the energy field), decides to play a practical joke on the Romulans for the battle damage caused in the earlier attack. It fabricates a gigantic ship-shaped balloon beside the Enterprise that the Romulans are drawn to attack. The Romulans, infuriated over the embarrassment of being tricked, give chase. Kirk immediately shows extreme fear at the prospect of returning to the cloud to escape the Romulans, and the Enterprise presses into Kirk's fear by taking the ship back in. The jokester personality of the computer begins to fade, as it realizes it had been tricked itself, and finally returns to normal. The Romulans, however, were so enraged over the balloon-ship ruse that they follow the Enterprise through the energy cloud and begin to experience a rash of jokes themselves.

Reception
Michelle Erica Green, in her 2011 TrekToday Retro Review said, there were "no scientific or speculative virtues," but it remains a favorite of many viewers for featuring the first canonical appearance of a holodeck in the Star Trek franchise, as well as the captain wearing a "Kirk is a Jerk" shirt. Green didn't care that most of the pranks were "at the level of 10-year-old humor," but noted "big plot holes" such as why Romulans were waiting to ambush the Enterprise. She loved that the computer demanded Kirk to say "pretty please," and replied to questions with "That is for me to know and you to find out." Green praised Majel Barrett who, "does a lovely job with the computer voice, which still sounds stiff and mechanical enough to be quite funny" even when making outrageous statements, and that "Kirk’s sputtering fury just makes it funnier...'Kirk is a Jerk,' indeed."

In 2016, SyFy noted this episode for presenting "the beginnings of the holodeck", a technological idea that later became a popular element in many later episodes.