About | RSS

Stung Eye

The eye of the bee holder.

Thinking in Tic Tac Toe

Thirty one years ago I typed tic tac toe code, found at the back of a computer magazine, into my VIC 20. I didn’t understand the code but I felt wizardly when the game popped up on the living room TV. Thirteen years later I would code my own tic tac toe game for the first time while learning to build Microsoft Access apps during my coding internship at MTS. I added the game as an easter egg to the time tracking app I built for the MTS Solutions Group.

The first two were written in flavours of BASIC. I’ve since coded tic tac toe in Pascal, Perl, Ruby and Clojurescript. The Pascal one was Connect Four, a 4-run tic tac toe with gravity.

All were written as code kata in the name of learning through experimentation. Sketching with code.

“This kind of coding as thinking out loud is known in the Agile methodology as a spike. It is meant to be as informal as possible. It’s the equivalent of whiteboarding. And just as whiteboarding sometimes leads to a formal solution, sometimes it’s benefit is in quickly and simply framing a problem. Coding allows us to whiteboard directly with data.”

This quote is from my friend Sam’s talk on Coding and Humanism for the UTSC Digital Pedagogy Institute.

Sam’s talk is embedded below. Worth the watch if you’re into such things as digital literacy in libraries, agency through computational thinking, formalism vs hermeneutics, amateurism, openness and pedagogy. ლ(´ڡ`ლ)

Sam’s talk got me thinking about how I learned to program computers. It also got me thinking about the privilege of having spent three decades thinking in code. I was fortunate to have access to a computer from a young age, with leisure time for computational tinkering, encouraging parents, friends, teachers and mentors. The gender, race and class issues present in the tech world have not been working against me.

Sketching with code. As an IT educator I’ve tried to balance the strict formalism required by technology with an informal exploratory approach to learning.

Sketching with empathy. To better serve all my students a recognition of privilege must also inform my teaching practice.

* * *

My most recent tic tac toe sketch can be played here. The computer plays randomly, not strategically. View the game’s source code, written while learning Clojurescript, Reagent and React.

Reading and Listening in 2015

I read fifteen books this past year. Ten less than 2014, four less than in 2013, three less than in 2012, and one less than in 2011. All fifteen books were read in deadtree format. Fourteen of them were fiction. One was non-fiction.

As you’ll see at the end of this post, my drop in book consumption can be attributed to my new found love of podcasts.

Books Read in 2015

Read in that order. No incompletes this year. The majority of these books were really great.

Top Three Books in 2015


“I must not fear. Fear is the mind-killer. Fear is the little-death that brings total obliteration. I will face my fear. I will permit it to pass over me and through me. And when it has gone past I will turn the inner eye to see its path. Where the fear has gone there will be nothing. Only I will remain.”

Publish 50 years ago, this sci-fi novel set 21,000 years in the future, has aged incredibly well.

Politics, religion, ecology, philosophy… Dune has it all. Forget top books of 2015, I’d say this would be one of my favourite books of all time. If forced to find fault, I’d point to sexism: The Bene Gesserit, a matriarchal order, develop a breeding program to produce the Kwisatz Haderach, a male Bene Gesserit who, being male, can do what they cannot do, can see what they cannot see.

Dune Messiah proved to be a solid follow up, and there were interesting similarities to the other far-future novel read in 2015, The Player of Games.

East of Eden

“The American Standard translation orders men to triumph over sin, and you can call sin ignorance. The King James translation makes a promise in ‘Thou shalt,’ meaning that men will surely triumph over sin. But the Hebrew word, the word timshel —'Thou mayest'— that gives a choice. It might be the most important word in the world. That says the way is open. That throws it right back on a man. For if 'Thou mayest’ — it is also true that 'Thou mayest not.’”

This book came highly recommend by Sam and it did not disappoint. The characters (even the minor ones) felt so real, their struggles so familiar.

Oh, the things we do for love (or the lack of).

Never Let Me Go

“All children have to be deceived if they are to grow up without trauma.”

What would you do to preserve the innocence of a group of children shuned by the rest of society? A melancholy story about purpose, love and mortality. Like Ishiguro’s The Remains of the Day (one of my top three from 2014) it’s also about memory and denial.

This book left me feeling sad and protective. Protective of my children but also of the entire human race. And that’s a weird feeling.

I don’t want to say much more, because spoilers, but I really enjoyed how well the author captured the way children see and interpret the adult world.

Podcasts in 2015

2015 was the year I discovered podcasts, which is why I read far fewer books this year. I listened to hundreds of hours worth of podcasts throughout the year. The podcasts I’ve been listening to, in alphabetical order, split into non-techical and coding categories:

General Interest Podcasts

Programming Related Podcasts

Top Three Podcast Episodes

Invisibilia - How to Become Batman

The story of a blind man who says expectations have helped him see. Literally, see.

Mystery Show - Case #3 Belt Buckle

A young boy finds an enchanting object in the street.

Reply All - #36 Today’s The Day.

PJ and Alex go outside. I highly recommend listening to episodes 1 through 35 first for context.

Audio Lectures and Audio Book in 2015

I only completed one set of audio lectures in 2015, but it was a doozy, a 42 hour review of Western philosophy. I also listend to the ebook version of Thinking, Fast and Slow, which was an amazing look at how we othen place too much faith in human intuition.

How To Think Visually Using Visual Analogies by Anna Vital

“If you know nothing else about visualization but pick the right analogy you are more than half way there.”

Sneak peek from today’s sale at Viscount Gort: Fantastic Four # 5 & 10, X-Men # 4, Hulk Hogan Finger from 1987 match in Wpg.

8-Bit skyline in Japan by @1041uuu.

More 1041uuu gifs can be found on 1041uuu.tumblr including the original daytime version of the above skyline.

Coding is Two Things

Coding is hard because it’s two things:

  1. Expressing ideas in the rigid syntax & grammar of a formal language.
  2. Problem solving.

While learning to code we often focus too much on the first. This is also true while teaching others to code.

This fall I’m going to highlight problem solving while teaching my intro programming courses. Below you will find some of the problem solving strategies I may adapt for my students.

Solving Problems in Five Acts

  1. Define the Problem
  2. Let it Simmer
  3. Plan a Solution
  4. Carry out the Plan
  5. Reflect

via: University of Waterloo Centre for Teaching Excellence

FOWL Problem Solving

Figure out What You’re Being Asked
Organize the Presented Data
Work out the Problem
Look Over Your Answer

via: Geekdad

George Pólya’s Problem Solving Techniques

  1. Understand the Problem
  2. Devise a Plan
  3. Carry out the Plan
  4. Look Back

via: George Melvin - Berkeley University

Also: Pólya’s book on the subject, How to Solve it - A New Aspect of Mathematical Method: Full PDF, AbeBooks, Amazon


How do you solve problems?

On reviewing this post Sam suggested emphasising hypothesis and testing when teaching these strategies. I agree that formulating a hypothesis during planning makes room for false starts, while testing adds rigure to the self-assesment of the “Look Back”/Reflect phases. The wonderful part about making these two steps explicit is that we now have something akin to the scientific method:

  1. Statement of the problem.
  2. Hypotheses as to the cause of the problem.
  3. Experiments designed to test each hypothesis.
  4. Predicted results of the experiments.
  5. Observed results of the experiments
  6. Conclusions from the results of the experiments.

Language geek note: The word solve comes from the Latin solvo, to loose an object bound, to release, set free, disengage, dissolve, take apart.

Related Posts on StungEye:

Bike To Work Day Winnipeg

Fancy bike thanks to the Natural Cycle pit stop at Omands creek.

Full Grown - Trees patiently grown into art and furniture.

Ceci n’est pas un visage.

Title: Time
Artist: Kim Laughton

This is a CG rendered face, not a photograph. It was modelled using ZBrush and rendered with Arnold. It took 32 hours to render. I wonder how long it took Kim Laughton to model/sculpt it?

More Hyper-realistic CG on the HyperRealCG Tumblr.

Reading and Listening in 2014

I read twenty-five books this past year. Six more than 2013, seven more than in 2012, and nine more than in 2011. Only one of the books was read on my Kobo, the rest were deadtree. Nine of them were non-fiction and sixteen of them were fiction.

Fiction Read in 2014

Read in that order. No duds this year, although I’ve got two incompletes:

I can normally savour a slow journey but Sterling & Gibson’s creation story for the Steampunk genre lost my interest. The stories in Friend, Follow, Text were harshing my mellow, so I’ve taken a break.

Top Three Fiction Reads

The Remains of the Day

We are a story we tell ourselves, parts of which we try to forget. A gentleman butler of World Ward Two-era Britain remembers so much but admits so little.

This book was full of comments penciled in by a previous reader that shaped the way I interpreted the story.

Ishiguro wrote the first draft of this novel in four weeks.

An Instance of the Fingerpost

A murder at Oxford in the 1660s told four times by four unreliable narrators. Each telling reveals more details and yet introduces more bias.

Shares many historical characters with Stephenson’s The System of the World (up next). It also shares this theme:

Early science is messy and pious. Early medical science more so.

System of the World

I feel like I know Isaac Newton, Gottfried Leibniz, Caroline of Ansbach and the rest of them. I feel like I’ve witnessed the Great Plague, London’s Great Fire, the end of Britain’s Stuart Dynasty, and the birth of modern thinking in science, religion, politics, and business.

I know I shouldn’t trust these feeling but I do.

Some 300 years ago Newton discovered a new System of the World. The predictive power of his three laws of motion made credible the scientific method. The twin calculus methods of Newton and Leibniz gave the scientific revolution it’s analytic strength.

This book is the third and final tome in Neal Stephenson's historical sci-fi trilogy the Baroque Cycle. It is also a tale about swashbuckling pirates, currency, coinage, courage and computation.

Non-Fiction Read in 2014

I fulfilled my goal of reading more non-fiction books. Many of these were inspired by a series of audio lectures on the Eastern intellectual tradition, others were inspired by parenthood as well as our work at Open Democracy Manitoba. They were read in this order:

Audio Lectures in 2014

Great Minds of the Eastern Intellectual Tradition - TGC - Grant Hardy - 17hrs - The best series of lectures I’ve listened to, ever. The content was mind expanding. The lecturing was enthralling.

Consciousness and It’s implications - TGC - Daniel N. Robinson - 6hrs - Difficult and at times even disturbing.

Headspace - Take 5 - A Guided Introduction to Meditation - I’ve been meditating on and off since 2000 (when I took a meditation course in the rain forest near Cape Tribulation, Australia). I’m 25 days into the program and I cannot recommend it enough. Try Take 10 on the Headspace app for free. It’s 10 days of 10 minute meditation sessions. You’ll thank me.

Currently Reading and Listening

Simon SwainEmergence as a game mechanic.

Simon demos a game programmed to play itself. The game involves flocking, resource management, colonization, economics, war and the exploration of deep space. Really.

Explore Simon Swain’s Deep Space.

Uninstalling social media apps for a short break. xoxo

Internet Bots for Fun & No Profit

My talk from last November’s BSides Winnipeg 2013 Security Conference.

I spoke about @abotlafia, my Twitter bot inspired by the “bot” in Umberto Eco’s 1988 novel Foucault’s Pendulum.

To show how little code is required to create automated accounts on Twitter I demo’d a few other bots that I’ve written. Here’s one that Tweets out a random number every five minutes. A modern day Numbers Station.

require 'chatterbot/dsl'

loop do
  tweet rand(1000000..99000000).to_s
  sleep 300

I closed with my motivations, the security/ethical implications of algorithmic social media accounts, and the possibility of a future where we are unable to determine who is real and who is a bot on the Internet.

The slides are online, as is the Ruby source code for the bots I wrote for the talk.

BSides Winnipeg 2013 was a two day B-Sides security conference held at the King’s Head in November 2013. All the talks are available online.

UPDATE - Abotlafia’s response to my talk:

The Four Stages of Learning.

Don’t know; Don’t care.
Don’t know; Do care.
Do Know; Do care.
Do Know; Don’t Care.

via: Trivium