The decisive moment didn't take place in the main cluster of bees, but out at the boxes, where scouts were building up. As soon as the number of scouts visible near the entrance to a box reached about 15—a threshold confirmed by other experiments—the bees at that box sensed that a quorum had been reached, and they returned to the swarm with the news.

"It was a race," Seeley says. "Which site was going to build up 15 bees first?"

Scouts from the chosen box then spread through the swarm, signaling that it was time to move. Once all the bees had warmed up, they lifted off for their new home, which, to no one's surprise, turned out to be the best of the five boxes.

The bees' rules for decision-making—seek a diversity of options, encourage a free competition among ideas, and use an effective mechanism to narrow choices—so impressed Seeley that he now uses them at Cornell as chairman of his department.

"I've applied what I've learned from the bees to run faculty meetings," he says. To avoid going into a meeting with his mind made up, hearing only what he wants to hear, and pressuring people to conform, Seeley asks his group to identify all the possibilities, kick their ideas around for a while, then vote by secret ballot. "It's exactly what the swarm bees do, which gives a group time to let the best ideas emerge and win. People are usually quite amenable to that."

In fact, almost any group that follows the bees' rules will make itself smarter, says James Surowiecki, author of The Wisdom of Crowds. "The analogy is really quite powerful. The bees are predicting which nest site will be best, and humans can do the same thing, even in the face of exceptionally complex decisions." Investors in the stock market, scientists on a research project, even kids at a county fair guessing the number of beans in a jar can be smart groups, he says, if their members are diverse, independent minded, and use a mechanism such as voting, auctioning, or averaging to reach a collective decision.

Take bettors at a horse race. Why are they so accurate at predicting the outcome of a race? At the moment the horses leave the starting gate, the odds posted on the pari-mutuel board, which are calculated from all bets put down, almost always predict the race's outcome: Horses with the lowest odds normally finish first, those with second lowest odds finish second, and so on. The reason, Surowiecki says, is that pari-mutuel betting is a nearly perfect machine for tapping into the wisdom of the crowd.

"If you ever go to the track, you find a really diverse group, experts who spend all day perusing daily race forms, people who know something about some kinds of horses, and others who are betting at random, like the woman who only likes black horses," he says. Like bees trying to make a decision, bettors gather all kinds of information, disagree with one another, and distill their collective judgment when they place their bets.

That's why it's so rare to win on a long shot.

THERE'S A SMALL PARK near the White House in Washington, D.C., where I like to watch flocks of pigeons swirl over the traffic and trees. Sooner or later, the birds come to rest on ledges of buildings surrounding the park. Then something disrupts them, and they're off again in synchronized flight.

The birds don't have a leader. No pigeon is telling the others what to do. Instead, they're each paying close attention to the pigeons next to them, each bird following simple rules as they wheel across the sky. These rules add up to another kind of swarm intelligence—one that has less to do with making decisions than with precisely coordinating movement.

Craig Reynolds, a computer graphics researcher, was curious about what these rules might be. So in 1986 he created a deceptively simple steering program called boids. In this simulation, generic birdlike objects, or boids, were each given three instructions: 1) avoid crowding nearby boids, 2) fly in the average direction of nearby boids, and 3) stay close to nearby boids. The result, when set in motion on a computer screen, was a convincing simulation of flocking, including lifelike and unpredictable movements.

At the time, Reynolds was looking for ways to depict animals realistically in TV shows and films. (Batman Returns in 1992 was the first movie to use his approach, portraying a swarm of bats and an army of penguins.) Today he works at Sony doing research for games, such as an algorithm that simulates in real time as many as 15,000 interacting birds, fish, or people.

By demonstrating the power of self-organizing models to mimic swarm behavior, Reynolds was also blazing the trail for robotics engineers. A team of robots that could coordinate its actions like a flock of birds could offer significant advantages over a solitary robot. Spread out over a large area, a group could function as a powerful mobile sensor net, gathering information about what's out there. If the group encountered something unexpected, it could adjust and respond quickly, even if the robots in the group weren't very sophisticated, just as ants are able to come up with various options by trial and error. If one member of the group were to break down, others could take its place. And, most important, control of the group could be decentralized, not dependent on a leader.

"In biology, if you look at groups with large numbers, there are very few examples where you have a central agent," says Vijay Kumar, a professor of mechanical engineering at the University of Pennsylvania. "Everything is very distributed: They don't all talk to each other. They act on local information. And they're all anonymous. I don't care who moves the chair, as long as somebody moves the chair. To go from one robot to multiple robots, you need all three of those ideas."