How Electronic "20 Questions" Games Work

It was about four years ago when I first saw a 20Q ball. The tiny handheld device scrolled text across its meager one-line screen, inviting me to challenge it in a game of 20 Questions. I immediately thought of an object I figured it wouldn't guess ("iPod") and began to play the game. After a series of slightly odd questions -- including "Does it bring joy to people?" -- the little ball gave its guess: "MP3 player." Wow. It was right.

So how does this 20Q device work? The short answer is "artificial intelligence." The long answer involves lots of practice. In 1988, Canadian inventor Robin Burgener programmed a neural network (a specialized form of computer program) capable of playing 20 Questions, but without a library of knowledge about common objects. He proceeded to teach it twenty questions about the object "cat," then handed the program (on floppy disk) to friends and encouraged them to play, recording their play sessions as it went. For 20Q, playing equals learning, as it develops "synaptic connections" whenever it receives answers to questions. It's able to reinforce connections by playing games over and over with different people, gradually learning which answers are correct and which aren't. (Thus it's difficult to "poison" the system by purposely giving it wrong answers.) The program can then use these connections to pose clarifying questions, eventually arriving at an answer.

By 1995, Burgener had a good body of connections in his neural network. He put a version of the 20Q program on the web and encouraged web visitors to play with it (thus training it in the process). After the online version of 20Q had played one million games (amassing 10 million synaptic connections in the process), Burgener boiled down the 20Q system into a simplified 20Q-on-a-chip version. The hardware version was incapable of learning, but contained information about the 2,000 most popular objects chosen by users of the online program. As such, it embodied a shocking "intelligence" that toy makers later put into the 20Q balls, now available at toy stores everywhere for under $15. (Specialized versions are also available, including a Harry Potter unit, and later versions of the handheld game have more information built-in.)

Today (or at least as of late 2006, the last time its online FAQ seems to have been updated), the online version of 20Q guesses correctly about 80% of the time, and if you allow it 25 questions, it claims a 98% success rate. With over 60 million games played online, the neural net continues to learn -- and this learning can be translated into future versions of the 20Q handheld games. In an interview with Kevin Kelly, Burgener said, "It is learning, but it is not increasing its success rate. What happens is that it is learning to play more kinds of people, people who don't speak English easily, or who have never played 20 questions, or who come from different cultures, and to understand more difficult kinds of things."

You can play 20Q Online for free, or pick up a handheld version at any reputable toy or game store. You can read a bit more about the game at Wikipedia or check out more on neural networks for a deeper understanding.

The Queen of Code: Remembering Grace Hopper
By Lynn Gilbert, CC BY-SA 4.0, Wikimedia Commons

Grace Hopper was a computing pioneer. She coined the term "computer bug" after finding a moth stuck inside Harvard's Mark II computer in 1947 (which in turn led to the term "debug," meaning solving problems in computer code). She did the foundational work that led to the COBOL programming language, used in mission-critical computing systems for decades (including today). She worked in World War II using very early computers to help end the war. When she retired from the U.S. Navy at age 79, she was the oldest active-duty commissioned officer in the service. Hopper, who was born on this day in 1906, is a hero of computing and a brilliant role model, but not many people know her story.

In this short documentary from FiveThirtyEight, directed by Gillian Jacobs, we learned about Grace Hopper from several biographers, archival photographs, and footage of her speaking in her later years. If you've never heard of Grace Hopper, or you're even vaguely interested in the history of computing or women in computing, this is a must-watch:

Watch Christmas Island’s Annual Crab Migration on Google Street View

Every year, the 45 million or so red crabs on the remote Australian territory of Christmas Island migrate en masse from their forest burrows down to the ocean to mate, and so the female crabs can release their eggs into the sea to hatch. The migration starts during the fall, and the number of crabs on the beach often peaks in December. This year, you don’t have to be on Christmas Island to witness the spectacular crustacean event, as New Atlas reports. You can see it on Google Street View.

Watching the sheer density of crabs scuttling across roads, boardwalks, and beaches is a rare visual treat. According to the Google blog, this year’s crabtacular finale is forecasted for December 16, and Parks Australia crab expert Alasdair Grigg will be there with the Street View Trekker to capture it. That is likely to be the day when crab populations on the beaches will be at their peak, giving you the best view of the action.

Crabs scuttle across the forest floor while a man with a Google Street View Trekker walks behind them.

Google Street View is already a repository for a number of armchair travel experiences. You can digitally explore remote locations in Antarctica, recreations of ancient cities, and even the International Space Station. You can essentially see the whole world without ever logging off your computer.

Sadly, because Street View isn’t live, you won’t be able to see the migration as it happens. The image collection won’t be available until sometime in early 2018. But it’ll be worth the wait, we promise. For a sneak preview, watch Parks Australia’s video of the 2012 event here.

[h/t New Atlas]


More from mental floss studios