AUDIE CORNISH, HOST:
From NPR News this ALL THINGS CONSIDERED. I'm Audie Cornish.
MELISSA BLOCK, HOST:
And I'm Melissa Block. By one estimate half of all stock trades now involve a computer which decides on its own to buy or sell. Computerized trading has helped markets function more efficiently, but it's also led to some spectacular messes. Just this month, one firm suddenly lost $440 million dollars because of a computer glitch. NPR's David Kestenbaum of Planet Money visited one of the fathers of computerized trading to explore how he got to this point.
DAVID KESTENBAUM, BYLINE: Thomas Petterfy grew up in Hungary after World War II. His first experience with trading happened when he was around 12. A friend went across the border to Austria and brought back something truly precious.
THOMAS PETTERFY: Juicy Fruit gum. These are beautiful yellow, Juicy Fruit gum sticks.
KESTENBAUM: Petterfy cut each stick into five small pieces, and sold the pieces to his friends at school for a profit.
PETTERFY: Eventually, the principal found out about this and called me down into his office and he said, well, where is your Communist conscience? And I didn't know what he was talking about.
KESTENBAUM: Was that your first time buying low and selling high?
PETTERFY: That is correct.
KESTENBAUM: Petterfy eventually makes his way to the United States, where he meets his first computer - a big boxy, calculator of a thing - and he falls in love, stays up all night programming it. And eventually, gets a job at a company that is trying to use computers and math to make money on Wall Street. In particular there are these complicated things called options or derivatives. They give you the right to buy, say, a certain stock at a certain price on a specific date. It's hard to calculate what one should cost, but Petterfy, with a computer, he finds a kind of secret formula.
PETTERFY: It took me about nine months to figure this out. But once I figured it out, it was a fantastic feeling.
KESTENBAUM: Because it meant there was a way to price them.
PETTERFY: That's right.
KESTENBAUM: And a way to make money. But this is 1977, and Petterfy has a problem. Trading isn't done on computers. You have to go stand in a pit on a trading floor and wave your hands around and shout. Petterfy can't bring his computer onto the floor, so he prints out mathematical tables on paper and puts the pages in a big binder. He brings this big binder down onto the trading floor.
PETTERFY: People looked at me - what the heck is that? And so I said, well, you know, these are my numbers that will help me trade hopefully. They made funny faces and, you know, many of them didn't understand my accent and it was - I didn't feel very welcome there.
KESTENBAUM: Every time Petterfy tries to use computers to trade, it's like the world just isn't ready for it yet. He hires some engineers who help him build these early tablet computers which work - though one burst into flames on the trading floor. It isn't until 1987 that Petterfy finally is able to take people out of the loop entirely. It happens at NASDAQ, the world's first electronic stock exchange. Meaning, there is no trading floor. You buy and sell by typing orders into a computer - a NASDAQ terminal. Petterfy, of course, doesn't want to have to type in orders. So, he and his engineers hack into the terminal. They wire it up to their computer, which starts trading up a storm; so many trades that a high up official with NASDAQ comes by to see what's going on. And the guy sees just this one terminal attached to a computer.
PETTERFY: He looks and looks and looks and he says, well, so tell me again how you are doing this? So I explained to him what's happening here. And then he says, I don't think you can do this, but I really don't think, but let me go back to my office and let you know.
KESTENBAUM: The man calls back and says I'm sorry. The NASDAQ rule book says you can't go cutting wires. All orders have to be entered through the keyboard. You have one week to fix it.
PETTERFY: So this was a problem.
KESTENBAUM: Petterfy and his engineers come up with a solution. Trades have to be entered on the keyboard? Fine. They build a machine to do that.
PETTERFY: So it was basically they were rubber fingers that were typing.
KESTENBAUM: You built a robot to type in the trades.
PETTERFY: We built a robot that types.
KESTENBAUM: What did that thing sound like when it was running?
PETTERFY: Like a machine gun. Brrrrr. Because it was typing so fast.
KESTENBAUM: Finally, in the 1990s exchanges started to let people just plug their computers directly into the markets. Today, Petterfy is one of the big players. The company he started, Interactive Brokers, does electronic trades on a mind-boggling scale. Forbes estimates his net worth is now over $5 billion dollars. Petterfy says automation has done some very good things for the world. It's made buying and selling stocks much, much cheaper for everyone. But Petterfy thinks this race for speed, it's doing more harm than good now. It's an arms race, like the U.S. had with the Soviets.
PETTERFY: We are competing at milliseconds. And whether you can shave off three milliseconds in the execution of an order has absolutely no social value.
KESTENBAUM: Petterfy is in favor of more regulation. Rules that will build in some safeguards and slow things down. The challenge, of course, people will try to find ways around those rules. There's always somebody willing to build a robot that types. David Kestenbaum, NPR News.
(SOUNDBITE OF MUSIC)
NPR transcripts are created on a rush deadline by a contractor for NPR, and accuracy and availability may vary. This text may not be in its final form and may be updated or revised in the future. Please be aware that the authoritative record of NPR's programming is the audio.