Disney’s Hall of Presidents finally added a Donald Trump robot. He’s really making an impact at Disney. Today he deported Aladdin and he gave Scrooge McDuck a tax break. How do late-night show writers come up with so many jokes? There is a method. And it’s surprisingly mathematical. When you have to write over a 100 topical jokes each day, there’s no time to wait for inspiration to strike. You need a reliable algorithm. Most Late Night Jokes you hear on TV are written using a step by step process, perfected to mass produce punchlines, rain or shine. When someone asked him about stakeholders, Trump said “I believe the word is fork.” To understand the formula we first need to review our Comedy Theory 101. From Aristotle, to Freud, to Gene Perret, who wrote for Bob Hope, thinkers have been identifying and naming the various triggers common to situations that make us laugh. The list goes on. For our formula we’re going to start by focusing on just two. Simply put, people laugh when they are surprised. This is where we get the familiar setup/punchline structure of a joke. People laugh when two things that seem very different are put together in a way that exposes a hidden similarity. If you were a chick, who’s the one guy you’d sleep with? John Stamos! For our setup, we can choose any story as long as it includes two different subjects that grab our audience’s attention. We already have, as the setup, the news that Disney made a Trump robot. So what about the punchline? To generate one, we just need to draw a surprising link between these two ideas. Here’s what the pros do. We’re going to free-associate two lists of words and phrases that come to mind when we think of our two topics. Now, we look for two items, one from each column, that have a logical connection, that activates as many of our laugh triggers as possible. The idea of Trump deporting a fictional character like Aladdin is surprising. It triggers recognition of pop culture knowledge, and gives Fallon’s liberal audience a sense of superiority to the president, because it makes him seem ridiculous and intolerant. Plus making fun of authority is a socially sanctioned way to misbehave. Now that we know our joke will involve Trump Deporting Aladdin, all we need to do is find a way to get there from the set up. There are many possibilities. A particularly reliable one is to ask Who/What/Where/Why/When/How questions about the set-up. In this case, “What did robot Trump do in Disney World?” does the trick. And just like that we have our joke. And yes we got two jokes for the price of one. But how does each late night show manage to find its own angle on the exact same story? Disney’s Hall of Fame debuted an animatronic President Trump today, whereas Jeff Sessions will debut at the Country Bear Jamboree. If your list is long enough, you’ll find an original joke. And now that you know how easy this joke-writing is, it kind of makes sense why Jimmy Fallon can’t stop smiling.