Ryan Seashore starts off every CodeNow workshop with a simple request — write out step-by-step instructions for making a peanut butter and jelly sandwich.A CodeNow teacher pretends to be a robot, and follows the students’ orders exactly as they’re written.
Students quickly find that asking a computer to perform an everyday task isn’t so easy.
The lesson: Good programming starts with organized, disciplined thinking. And one mistake can cause everything to crash.
Coding is a hot subject right now in Florida schools. Florida lawmakers allowed students to substitute computer programming for a math or science high school graduation requirement.
Lawmakers considered allowing students to take coding instead of physical education or a foreign language, before abandoning the ideas.
And a small army of non-profits — CodeNow, Code.org, Black Girls Code, Girls Who Code — are teaching students across the state how to create a program.
They have several goals.
- Give students a crack at learning a lucrative skill.
- Create a pipeline of homegrown workers for Florida companies.
- And add some diversity to a largely white, male industry.
But a skill for the new economy usually starts with a lesson in logic, a classic discipline.
On a recent Sunday morning at downtown Miami’s Venture Hive tech workshop, two dozen students are applying logic to design simple games using the programming language, Ruby.
Two students are trying to write a program which will print colored words on the screen.
“Let’s just do blue,” one student said.
They type in their commands. They run the program.
But something fails.
Downcast, the student read the error message.
“Wrong number of arguments.”
Many of the students at the CodeNow workshop, like Yoami Garcia, had never done any computer programming.
She’ll be a junior this fall at Archimedian Conservatory, a Miami charter school. She wants to be a journalist and thought coding would be useful.
“I love logic and math,” she said. “So I thought maybe I’d be actually good at this too.”
She was a little frustrated by the trial and error.
“I don’t like that. It gets a little bit annoying, but I mean, that’s how you’re going to learn I guess.”
Most students get a taste of logic problems in math class – puzzling out which kid lives in the red house; or who owns the dog. But the type of formal logic conceived by Aristotle or the Stoics usually doesn’t come until college philosophy courses.
David Dill teaches computer science at Stanford University. He says it seems a long way from Plato to Bill Gates, but philosophy and computer science are intertwined.
“Every once and a while I encounter a little ancient history,” he said, “and realize that there are so many things we live with now that are descended from something that somebody invented thousands of years ago.”
The father of computer science, Alan Turing, was as much a philosopher as he was a mathematician or military code-breaker. And Dill said there are still direct ties.
“Programming languages that we use now are descended from work that people did in logic,” he said. “For example, Javascript is based on a language called Scheme, which is based on a language called Lisp, which is derived from lambda calculus, which is a language designed by a logician for studying logic.”
Logic and problem solving are what hooked Kareem Grant on coding. Grant first learned coding about a decade ago. But he only started working as a professional programmer in New York after volunteering with CodeNow.
He’s one of the teachers at Miami’s weekend camp.
Grant loves the challenge of turning an idea into something real. The feeling of solving every little puzzle to make a piece of programming work is the next best thing to having superpowers, he said.
“The ruthless logic,” he said. “One semicolon that’s off; one comma that’s off. You miss an end statement in Ruby; everything breaks. But then you understand. You become disciplined…because it took away two hours of your life and you’re never going to let that happen again.”