Posts in Category: Professional

Impetus for Change

For any constant readers who don't know, I've accepted a job offer and I'm moving on from Haemonetics. Moving on, once again, from Bisonweb. In order to do so, I've had to come to terms with how things ended at Gamesys, and basically, and as stupid as it sounds, had to forgive the notion of permanent employment and the failures I've suffered at its hands.

When things fell apart at Gamesys, I was angry, I was bitter, and I didn't want to be. I wanted to be strong, I wanted to be productive, and, if I couldn't have what I had at Gamesys, I wanted just a crap-ton of work to bury myself in.

Coincidentally, Haemonetics had a crap-ton of work that they needed to get done, and no luxury of time. Sounded good, so I signed up. Bisonweb rides again. It's funny how, three times, a contract at Bisonweb has rescued me from a bad employment situation. I probably should give some thought to that and acknowledge the role they've played in my career. Maybe that's a blog post for another day.

Anyway, it didn't take long for all that pent-up crap that I was feeling but not acknowledging about Gamesys to get into my head. I started going to a not good place. You know what? Fuck it. Call it what it is, Liam. I was in a full-blown state of anxiety for two months.

For those of you keeping score at home, this is what anxiety looks like for Liam: No sleep. Sleep is for people who can take care of their shit. You want to rest? Stop fucking up, idiot. Also, increased work hours. I'm not talking, like, an extra ten hours a week. I'm not talking about maybe picking up some extra time on the weekend or after the kids go to bed. I'm talking about 40 extra hours a week, that I didn't bill for, busting my ass because ... I dunno... because the big bad boogieman is going to get me if I slow down? Anxious Liam doesn't stop to take a look at what he's doing. It's too late for that. It's time to buckle down and put on the ol' hermit-hat and just get the job fucking done. I'm usually wide-eyed, looking in the direction of my laptop, and if you're talking to me, you're getting maybe a quarter of my attention. Not because I don't appreciate you or care what you have to say, but because I need to be on top of things.

Needless to say, last November and December, and more than a little into January (but I think I'd moved past it by February) were my own little Hell. It was a Hell of my own making, I accept. It was my unwillingness to stop, take a look at where I'd come since September when my job fell apart, fear of judgment, and the pride that says, "You can do it yourself. Just work a little harder." I didn't ask for help. I didn't speak out. And I didn't slow down. Eventually, I hit a breaking point and talked to my team lead. I forbade myself from working any overtime for a couple of months, and I got my life back on track. Boy, I bet I was a bundle of fucking joy to be around. I'm sure Kim could tell you.

All right, that part's done. It's said. No takesies-backsies. Anyway, I'll admit that things stagnated at Haemonetics. We've been waiting for new work to be approved for a couple of months, and I know that, despite the attitude in Edmonton, head office doesn't like using contractors. I didn't start a campaign to get a new job, but when my friend Robb asked about how I was doing, I was honest. I did all the stuff I talked about in the other blog post, forgave an abstract concept, and took the job.

And they all lived happily ever after, right?

Not so much.

There was a fair amount of anxiety that came with that decision. The new job has a whole bunch of new responsibilities, challenges, and growth that will be pushed on me. I'm equal to the task. But, you know, things. And the past. And anxiety telling me things that aren't true, sending my mind in circles, trying to solve problems I haven't been given yet.

I took control. I took a step back. You know how hard it was to make myself take that step back? Let's just say that, when I agreed to meet with the bosses at IntelliWave, I knew I was going to have to have this conversation with myself. That was December 7. I managed to push it off by just about a month before I finally managed to make it happen. The first step was the hardest. I took out a notebook. I took out a pen. It's galling to me to realize that up until that time, I hadn't sat down and written anything the whole time during the application process, or anything for a couple of weeks before that. That first conversation with myself didn't really go so smoothly. I chit-chatted a little bit. Not exactly about the weather, but, you know, things that weren't consequential to where I needed to get. Still, as I wrote in that entry, "For now, it feels good to just spray some ink onto the page." I knew I didn't have it in me then, but I knew what I needed to do, at least.

Finally, I got on my ass and sat in front of that notebook until words came out. And I wrote, and I wrote. I wrote about what went wrong at Gamesys, I wrote about where I had failed, where I had not failed, and what lessons I would take from that experience. Finally, I wrote down some intentions that I am going to take with me to IntelliWave, to start the next stage of my career, with a company I am ready to believe in. I think this will help me get a good jump-start on my new job, and I am happy to say that, with this analysis, the anxiety is gone, replaced with an almost giddy anticipation. I get to work with my friend Robb again, with tools and process I can help choose. Let's get to work!

Originally, the intentions I wrote about were going to be the thrust of this blog post, but I realized I needed to get the rest of it out, the bits about the anxiety, both at the end of 2015 and at the end of 2016. I do intend to write about the intentions, their genesis, and what it can mean, but I've exhausted my reserve of words today, and I'm sure you've got... oh... something to do besides reading more of this.

The Evening Redness in the West — or — Forgiveness all Around

I'm not going to lie, when I left Gamesys, I was done. Done with permanent employment, done with "career paths" and "the promise of advancement." I was angry, sad, and disappointed. I went back into contracting, sure that I would never go permanent again. It was a fool's notion. A silly thought that I could stick it out, that there was even something for me in that world. I turned back to contracting with Haemonetics. It was something I knew, somewhere I could just put my head down and work.

Jon Secada, you crazy sage, you, you were right when you said that Time Heals all wounds.

The fact is, the first eight months or so of my Haemonetics time was very cathartic. I had my head down the majority of the time, working copious overtime, and getting stuff done. There were no politics, no worries about getting shut down, and it was something I was familiar with.

Eventually, though, I started feeling the pull of the things I'd had at Gamesys. Leadership, mentoring, a little agency where process is involved. Let's not kid ourselves, when you're living under ISO-13485, there isn't much room for a contract developer to have any sort of opinions about the software development lifecycle. Regulations are strict, and if a company wants to be in that space, they need to meet or exceed those rules every single time.

I'm not saying I'm a guy who plays fast and loose with the rules. I work with what I'm given, and I do my best. But I do my best when I feel like I have a voice. When I feel like I can have a say, and maybe in a place that isn't quite so locked-down.

Three weeks ago, I started interviewing for a position. It sounded great. One of those positions that doesn't seem to come along very often. Something a lot like what Gamesys was, without the heavy breath of head-office on the back of my neck. I made my way through the twists and turns of the hiring process at Intelliwave, and they seem to like me as much as I like them. The TL;DR of this piece (not just at the end, Cliff, but buried in the middle of the story. Beat THAT...) is that I've accepted a position, and I start on January 16th.

What am I going to be doing? Well, it's been made clear to me that I'm one of two senior developers on the team, and the way the team grows and accommodates a backlog that is as impressive in its scope as it is in its ambition is going to be, at least partially, up to us. But for the most part, I'm going to be heading up the web development. Robb (you may know him as the double-b, I sure do) will be in charge of the back-end services, and together, we will make great things, build an awesome team, and have a lot of fun doing it.

I'll miss my spot at Haemonetics. They've turned a pretty big corner since the tall-cubicle days of 2009. The open concept is something I feel like would be a benefit to pretty much any development office, and I think Robb and I can take a bit of credit there too, maybe, as we dismantled part of our cubicle partition to more easily collaborate, way back in the day.

So, I've forgiven myself and Gamesys, and, absurdly enough, permanent employment. I really want this to be the one, the position where I can see myself retiring in ... ah, whenever they nail the coffin shut, I suppose, and I'm going to give it, and myself, every opportunity to make that happen.

Thanks, Haemonetics, for being there when I needed you.


The Boy – 20 to 40 Gratitudes Part 2

Helping to raise Nick helped me to understand how little I know about anything. I have a hard time remembering what life was like before Nick, my attitudes and my opinions about parenting. I mean, I suspect I was pretty low-key. I don't usually have a lot of opinions about things I don't know anything about. But if I did have some arrogance or something about how I would do things differently, consider that squashed. I knew nothing.

I still have a lot to learn about parenting, but I'm getting a little better at understanding what it is that I don't know yet. I credit Nick with taking the brunt of my ignorance. He's managed pretty well despite numerous fights about food, about homework, about lots of stuff. And he's figured so many things out recently, about growing up. And it feels like it's happening too fast. Applying for jobs, being all tall and all, just doing teenagery things.

There's a lot to appreciate about a son like Nick, so I'll throw some out there and hope I don't miss any glaring ones (though I probably will. I'm really old too, now).

I appreciate Nick's sense of humour. He likes and appreciates a good pun and appropriately cringes at a bad one. It makes my day when I hear him cracking the same kind of joke that I would.

Nick has a good work ethic. I first noticed it when we were pulling the shingles off the roof of the shed that would eventually become (and still will eventually become) the chicken coop. But I've seen it since then. And it is amazing to watch.

I'm so excited to see what Nick ends up doing with his life. He has a lot of tools in place and he has a sincere desire to do good in the world. I appreciate having that to look forward to all over again, now that I'm rigidly entrenched in my own career -- a career that I enjoy and that I appreciate, but something that does not always offer much in the way of excitement or surprise.

So, for the second time in as many days, I have to thank Kim. Without her, I would never have met this funny, sincere, dynamic kid, and my life would have been the poorer for it.

Job Hunting

This is one of those catch-up posts where, normally, I'd apologize for not posting more often, wring my hands, and hope that you'll forgive me. But it turns out that I'm not worried so much anymore about posting on a schedule or making sure that I have something up. I don't really know how many people read this blog, and I'm sure the inconsistent nature of my posts is more than a little bit to blame for the lack of engagement (read: comments). Again, I don't know that it matters too much to me. It's good to have this place to put stuff, and if people enjoy reading it, then there it is. But I'm not apologizing for leaving you in the lurch. There's too much content on the web to worry about how you guys are filling your surfing hours. (Do people even surf anymore? Like web-surfing, I mean. I don't know if it can be called that anymore. Maybe a topic for another day...

Anyway, that was a long and rambly introduction to a catch-up post where I tell you what I've been up to professionally since we last had a chat. I'm thinking about a series of these posts, but who knows? Maybe you'd come to expect them of me...

A Gamesy No More

Sometime in the beginning or middle of September, I found out that Gamesys Canada was going under. Poker was no longer a viable product and they didn't see the need in keeping an office open when our so-called "expertise" was not being used. I'll be clear here. They did open the office in Canada because there was a lot of poker knowledge in the area, and there were some people on the team who knew (and presumably still know) a lot about poker. However, I think it's fair to say that the majority of the people on the team, and all but one or two developers who were actually attached to the poker team had more than a passing familiarity with poker. I know I'm no expert. I understand the rules, but that's about the extent. What we had, instead, was a great group of programmers who cared about the product they were making, and cared about the job they were doing. However, I can understand the reasoning. London's first priority has to be the London office, and anything that gets done in Edmonton (aside from the aforementioned speciality of the Edmonton office) would be taking away work from the folks in London. So they made the decision to close the doors.

History repeating

I'm no stranger to getting the axe. I mean, I was never technically let go at Intuit. They just made it impossible for me to keep working there. But I've had contracts cut short because of circumstances beyond my control. I've been in the situation where my contract would not be picked up, both my fault and not my fault. And I've seen the destruction of some pretty fantastic development teams. It's part of the job. If the project isn't going well, or if it is going well and something goes wrong somewhere else, or if someone is just politically savvy and does not want your team to succeed, it will happen. So I've learned to harden my heart against that sort of thing. I took all the personal out of it and started looking around.

More history repeating

I hit up some of my old haunts. I talked to a friend at Telus. I'd done some work there, and they had a reasonably good opinion of me. I talked to a friend at Haemonetics. I talked to my old boss from Intuit. They were all receptive. I answered a couple of ads on the internet. There was lots of interest, but I stuck with Haemonetics. It is a contract and they hired me with a minimum of muss and/or fuss. I started there after a reasonable period that meant I also got to keep my ridiculously generous severance package from Gamesys. In a way, it's good to be back where I know my role. I know the code base. I know the people. And if I hadn't just worked at Gamesys, it would be perfect.

Used to something more

At Gamesys, we had something really going. We had a ton of momentum, we had a group of personalities who meshed really well. We had some big brains, but the big egos weren't in evidence. We had collaboration, and we had a willingness and an agency to change things that weren't working so well. Code review process unnecessarily sterile? Change it up! Turn it into meetings where we can discuss instead of staring at a web page, trying to focus on green and red highlighted text. Finding there isn't enough time between one meeting and the next to answer the questions that we need answered to commit to things? Change the first meeting time. Honestly, we were running over the problems and squashing them flat. I felt like we were growing as a team and only getting better.

Receive ticket, commence work

Maybe it's the vast difference of this contract to the work at Gamesys. Maybe I reached the top of the mountain and don't want to climb down. Maybe it's all that personal I took out of the equation when I started looking for another job coming back to bite me in the ass. But I'm dissatisfied. I want to effect change. I want to make things better. But that's not my role here. My role here is to implement, document, and test tickets. I can do that. I have been doing that. But it's hard. And it's hard to feel valuable when I'm basically just filling out forms, it feels like. I'll do it, but it doesn't feel really fulfilling. Meanwhile, there are people who are doing the kind of work that I was doing before this. There was the possibility of a position with a company called Verafy, where they were working on some exciting software, and I would have gone in as a team lead and principle software developer and been able to mould the team to a certain extent. Instead, I'm doing my best to take requirements and turn them into code. The isolation from the other developers is difficult, though that won't be for long, and there are some additions coming to the team that should be exciting. I guess I'm just spoiled from my time at Gamesys. That'll wear off, I'm sure, and I'll go back to being the cantankerous bastard I was before.

There you have it. Totally uneven, no real point to it, but it's a post -- an update on where I am professionally.

Me and the Double-B

A Brief History of Time

Robb Reid (a.k.a, the Double-B) and I have worked together on and off since 2008, and on the auspicious occasion of his first day at a new job, I figured that I would chronicle our adventures together.

2008 - A Meeting of the Minds

I started at Haemonetics, after leaving Intuit, in October 2008. There were a lot of people to meet and whose names I would have to remember. Robb was one of these people. He did not like me.

As time went on, I think he warmed to me, so much so that after a few weeks, I came to understand why Dennis called him the RMDB. Robb knows his movies and TV, and nobody can tell me otherwise.

2009 - A New Opportunity

When Obama became president and destroyed the project I was working on (Thanks, Obama!), I found a new contract very quickly. They were looking for another developer, and I immediately thought of Robb. So we spent some time working together (albeit on different projects) at Accenture. I think that's when we started going for lunch together every day.

Late 2009 - Back to the Beginning

Robb and I both got work at Haemonetics on a new and improved project that was safe from the whims of government, being a commercial product. We worked there together, being the first two contractors on the project, and survived the (at least perceived) scorn of some of the permanent people there. We dismantled our cubicle and created the Collaboratron, which was basically just a hole in the wall where we could share ideas.

Toward the end of the first contract, we were both renewed, but Robb found a different job and took it, leaving me to patch up the collaboratron hole and pick up the pieces.

Late 2010 - 2014 -- Two Roads Diverged

Robb continued in his job with the government as I continued to pick up contracts. The work at Haemonetics dried up and I found Intuit, POSP (my own sojourn into government work), Telus, and Intuit once more. Toward the end of my contract with Intuit, Robb got in contact. He was starting a new job at Gamesys, a company I'd heard of only tangentially to that point, and we started going for lunches again.

2014 - 2015 -- Gamesies

Through March and April of 2014, I tried to get hired by Gamesys. And in May of that year, Robb and I were reunited at Gamesys. We worked together. But in July 2015, all of that changed.

2015 -- Gone Again

Robb accepted a position with IntelliWave, some kind of tracking company that uses RFID to save oil companies money. I understand the reasons he took the job, but it leaves me Robbless yet again.

I wish Robb well at his new job. He starts today, and I wrote this as much to wish him well as to mark his passing.

Game Programming

For the last week, James and I have been working on a game.

I was going to wait until we were done, until we had deployed the finished and polished product somewhere, but I'm excited by the work we're doing, and I wanted to talk about it, so here it is.


In 1981, Intellivision released Astrosmash, a game that was released to match Atari's Asteroids game. Instead of flying around the screen, though, you're stuck to the bottom, shooting upwards. Meteors, seekers, and bombs of varying sizes and speeds fall from the sky as you zip back and forth across the screen and try to line the little buggers up to blast them from the sky.

My memory of this game from my childhood is incredibly intense -- from the descending tones of the bomb as it makes its way to the ground to individual asteroids in which I could see faces. I used to play this game for hours at a time. We didn't have an internet available to us, and it was a reasonably diverting way to spend some time.


The first game I worked on using the technology we picked was through a tutorial. I recreated the Nokia snake game where a snake eats an apple and grows longer. If the head runs into the body or the walls, the game is over. The finished product was really nice. It was simplistic, but it worked, and it was fun. Which made me think of the Intellivision. Simplistic but fun was almost their calling card. So I decided on the simplest game I could think of.

The Devil in the Details

Nick implemented a version of the game in scratch that worked. If we were interested in a working, and somewhat reasonable facsimile, we could have stopped there. Instead, we wanted to look into the guts of the game, figure out what made it work, what made it fun, and try to implement that. There is a lot to this game.

When the game is ready, and I write a post about it, I'll go into the details I'm talking about. I can talk now about how the jerkiness of the ship in the original intellivision game made it a lot tougher. I can talk about how at faster levels the speed of the meteors is so intense, you're almost shooting them by accident as you try to avoid the faster ones. I can talk about how there are never more than five bad guys on the screen at a time and the big guys split when you hit them, but only if there are enough open slots for two new bad guys to fit. There's a bigger list of things with this game, but again, I want to save that for when we've solved all the problems and have something polished. For now, suffice it to say, there is a lot of tweaking of algorithms to up the danger and keep the game fun.

The Technology

Both James and I are using JavaScript in some flavour or another at work, and we decided that we would tackle this project in Phaser, an HTML5 Javascript library. It may be slower to get something out than scratch, but it seems a lot more extensible, and full featured. I'm very proud to see what Nick has accomplished. I just want to do something with code.

Phaser, for those of you who are intrigued, is, as far as I can see, a really good, fully-featured game programming environment. It has libraries to help you, but leaves the logic and the game itself up to you. One day, I will make a write-up on phaser itself, and you will see how simple it is to make something quickly in phaser.

But Where Can I Play It?

James has put a copy of the game up on his site, though as of this writing it hasn't been updated in a bit, and the ship is slow, and the enemies are completely unthreatening, but it's a game that we made, that has score, and good guy, and bad guy, and game over. I'll be deploying something to my site as well, but not just now.

That's it for now.


A Dubious Anniversary

Six years ago today, everything started to go downhill.

I'll grant that things weren't helped by the passing of my mother on the 25th of February, that year. I was sad, but I was processing. My family was supportive, and I had a good and productive job that I worked with a bunch of like-minded people, all of whom were interested in getting better and getting the job done. Then, the bottom fell out.

The majority of the people working on the project were contractors. There weren't any big egoes. Everything was going well. I spent all of the previous December doing manual testing, and I didn't even mind.

Let's keep in mind that this was the first work that I'd done after leaving Intuit. I felt, for the last six months at Intuit, like I was drifting, with nothing important to work on. I joined Haemonetics and was almost immediately put to work, learning a new framework, and it felt like urgent, important work. I felt valued.

Then Haemonetics lost the contract.

I don't know how these things work. It sounded like the work was guaranteed, that we were in it for the long haul. But I guess if there are enough dollars thrown around, you can get out of pretty much anything.

"It's not the work that you guys did. The Project Office loves that."

"They're just as surprised and upset about it as we are!"

These are the things they told us when they called all of the contractors on the project into the room, save one, and let us know that our services were no longer required.

It wasn't the end of the world. I mean, I wasn't being let go because of performance issues. And I still had friends who had jobs. I could maybe lean on one of them to find something. And I did. Before the end of that week, I had something lined up through a friend of a friend.

It wasn't the end of the world, but it was a serious rupture to the momentum I'd built up in recovering from the loss of my mom.

I started the next contract, and I had big ambitions to be everything they needed. I would work just as hard there as I had at Haemonetics and impress them every bit as much. I could do that. I would do that. Anything else was unacceptable.

Then I didn't.

Things weren't the same at the new place. There was no collaboration. There was no support. Where I'd had good conversations over design decisions, and collaborative efforts were the name of the game, now there was finger-pointing, blame-dropping, and crickets, or worse, figure-it-out-yourself-contractor when I asked for some help. My motivation to excel waned, my work ethic withered, and, though I redeemed myself at the end, their decision not to renew my contract at the end of the eight weeks was understandable, and probably nothing more than good business sense.

I'd lost myself in uncertainty, anxiety, and depression, and I let that affect my work, my family, and everything else. I remember leaving work one afternoon and just wandering downtown Edmonton. I couldn't bring myself to face the work that I had to do because I'd built it all up so high in my mind and I didn't have the heart to tackle it.

I finally hit rock bottom when a design came due and I had done almost nothing on it. I bounced back pretty quickly, stayed up all night and finished the design properly, according to their template, and didn't charge for that time, but I'd embarrassed the hell out of myself professionally, and the damage was done.

One of the project managers, one that I felt some animosity towards over some interactions we'd had before, sat down with me and told me that the work I'd been doing was not good enough, and that, while they were not yet ready to get rid of me, they had considered it, and I had better improve. I replied that I knew the work I'd done was not good enough, and that I would do better.

Over the last weeks of the contract, I attempted to do better. I put everything to the side -- family, friends, interests -- and threw myself into work. I worked sixteen hours, four days straight, knocking out bugs for a release that was already far past due, and left on the last day of my contract, after midnight. I'd skipped supper because I didn't have a key anymore, and there was one guy left to see me off.

After the contract, the friend of a friend who'd gotten me the job contacted me. He'd heard from the office manager who'd wanted to pass something along. I tensed up as soon as I heard that. That crippling anxiety that I'd thought I had left behind when I hit bottom came rushing back into me. What if they were planning on suing me? I couldn't afford that.

Instead, he told me that the manager wanted to thank me for the extra time I'd put into the project before my contract was up. The bug count had gone down dramatically and it was largely due to the work I'd done. I guess you could call it redemption, but I got the distinct impression that they were happy to be rid of me.

Every year after that, starting with the 25th of February, anxiety creeps over me, a ghost with icy fingers crawling through my guts. The secret shame of that horrible failure of a contract steals over me and I find myself almost paralyzed by my own inadequacy. It's gotten better in recent years. The years when I was at Intuit kept me so busy I didn't have time to feel one way or the other, and the contract at Telus was much the same.

This year, I've started to go down that road again. Some of it has to do with Timehop, an application that unearths your old social media posts from the same day in the past. I've been reading posts from my time at Haemonetics, and as this day got closer, I was feeling more and more dread.

Today, I've decided that enough is enough. I'm coming clean about the darkest and most shameful time in my life. I'm making a commitment to moving forward in my life instead of spinning my wheels and looking behind me for a thing that will only chase me if I look for it. And I'm deleting Timehop.

Timehop, you were a fun waste of five minutes now and then when I took the time to look at you, but you're in my way, and I'm saying good bye.

I hope you will forgive the lack of editing on this post. It was a tough one to write and if I think about it too much, I'll chicken out and not publish it.

Thanks for listening.

Beginner’s Intro to Programming: Lesson 1

Programming Course: Lesson one

In the first class of programming course, we talked about a couple of ideas.

First, we talked about Boolean logic and the notion of TRUE and FALSE. These two things are very simple to think about. The examples we used involved a couple of students and a sibling.

We said "Nick is a boy" is TRUE. We also said that "Ryan is a boy" is TRUE. And we said that "Lily is a boy" is FALSE. Using that, we could expand to talk about the logical operators.

"Nick is a boy" AND "Ryan is a boy" is TRUE. "Nick is a boy" OR "Ryan is a boy" is TRUE. "Nick is a boy" AND "Lily is a boy" is FALSE. "Nick is a boy" OR "Lily is a boy" is TRUE. "Lily is a boy" AND "Nick is a boy" is FALSE. "Lily is a boy" OR "Nick is a boy" is TRUE.

We also looked at logical negation, or the idea that NOT TRUE is FALSE and NOT FALSE is TRUE. This gets a little confusing when you try to fit it into English, but we tried:

NOT "Nick is a boy" is FALSE. NOT "Lily is a boy" is TRUE.

Then we looked into code for these logical operators.

AND is &&, OR is ||, and NOT is !. Using T for TRUE and F for FALSE, we get the following values:

T && T == T T && F == F F && T == F F && F == F T || T == T T || F == T F || T == T F || F == F !T == F !F == T

There's a lot of ground to cover in logic, particularly with Boolean Algebra, but that got us started, so we'll leave off there, with a final note: If you're interested in more, you can find it here.

Moving on, we talked about variables. Variables are a little tricky because they're pretty different in different languages. But for our purposes, beginning programming, we discussed what variables are for. Variables are there to hold stuff for us, so we can do work without always knowing what values are going to be.

We talked about a program that prints the greater of two numbers. The simplest way to do this, if you know the two numbers going in is to just write one line of code:


if you're comparing two numbers and 1 is the lower one. The problem is, when you're programming things that are smarter than that, you won't be able to know in advance what the values you're using are. So, we added variables to our problem, like this:

var input1 = 1; var input2 = 2;

So, we have two variables that we can use. We can change them if we want to, we can read them, we can compare them, we can print them out to the screen:


So, knowing that we can store things, and knowing that computers are good at making decisions, we need to find out HOW a computer makes decisions.

The easiest way for that is with a conditional statement -- for our purposes, an if-statement:

if ([boolean equation here]) { [do the stuff you want to do here] }

That's the syntax for an if-statement. We learned about boolean equations above, but we have to take a little time to learn a way to make those TRUE and FALSE values.

One way is to use mathematical comparators: >, <, ==, !=, >=, <= That is, greater-than, less-than, equal-to, not-equal-to, greater-than-or-equal-to, and less-than-or-equal-to. There are more ways than this to generate boolean values, but these are the simplest, and they suit our purposes well. Greater than is a great place to start, because we want to see which is the biggest number of our two:

if (input1 > input2) { console.log("The bigger number is input1, which is: " + input1); }

Ok, there's a little bit to talk about here. The console.log line has a + sign in it, but for now, let's just say that when you're dealing with a string, it just mashes everything together.

The first line is what we're most concerned with. Greater than is true if the first number is bigger than the second. So, if input1 is 10 and input2 is 2, this would evaluate to true. The curly-braces {} hold everything that happens if this case is true. So you could have more than one line inside those curly-braces and it would only execute if the condition in line 1 is true.

Great, so assuming input1 is bigger than input2, we're done. But, as we said, we can't assume that. So, we need more. We could just add:

if (input2 > input1) { console.log("The bigger number is input2, which is: " + input2); }

That would definitely get us further down the road. I mean, you've got the cases where one is bigger or the other is bigger, and that should be just about it, right? Except that we're missing one case. What about if they're equal? That should be easy by now. We have another comparator to check equality:

if (input1 == input2) { console.log("input1 and input2 are equal, and their value is: " + input1); }

And that closes all the cases. If neither one is bigger, then they must be equal. So, we're done. But that is a little bit of a bog. Three separate if statements. What if our comparison was more complex?

if (input1 > 0 && input2 > 0 && (input1 + input2) < 100) { console.log("both are greater than zero, and their sum is less than 100"); }

That's great, but how would you do something if that wasn't true?

Sure, you could code it explicitly:

if (input1 < 0 || input2 < 0 || (input1 + input2) > 100) { console.log("no they aren't"); }

But there's a simpler way:

if (input1 > 0 && input2 > 0 && (input1 + input2) > 100) { console.log("both are greater than zero, and their sum is less than 100"); } else { console.log("no they aren't"); }

That's the all-powerful else. If the condition in the initial if-statement is true, the block under it is executed. However, if the condition is false, then you can put an else statement there to be executed instead. You can chain if-else statements so they look like this:

if([initial boolean equation]) { [first code block] } else if ([second boolean equation]) { [second code block] } else { [default code block] }

So, if we go back to our original problem, we have something we can use for that:

if (input1 > input2) { console.log("The bigger number is input1, which is: " + input1); } else if (input2 > input1) { console.log("The bigger number is input2, which is: " + input2); } else { console.log("input1 and input2 are equal, and their value is: " + input1); }

We ended the lesson by coding up the reverse of this, which was to print out the smaller of two numbers, or if they were equal, then to print out the word equal. Most answers looked something like this:

var input1 = 1; var input2 = 2;

if (input1 < input2) { console.log(input1); } else if (input2 < input1) { console.log(input2); } else { console.log("Equal"); }

Then I tested the programs by entering different values for the variables, one where input1 was bigger, one where input2 was bigger, and one where they were equal.

There was a lot to think about by the end of the lesson, and the syntax can sometimes be tricky, that's for sure. It starts out being frustrating that the language is so picky, especially for students who are used to the ambiguity of human languages, but once you learn to properly state things, there's almost no opportunity to be misunderstood. Learning how to properly state things is what makes someone a programmer.

The Third Thing I Am

Career choices are a funny thing. I wasn't thinking about a career as a programmer when I decided to go to university. I wanted to be a journalist. I wanted to be a professional writer, and I knew that the University of Lethbridge was a school that had a journalism transfer to Saskatoon. Little did I know that the journalism program at the Lethbridge Community College was all that I would have needed for that -- two years less and more chance I'd get in.

While I was looking through the calendar for the U of L, I started thinking about the science courses they had to offer. Being a Liberal Education university, I was going to have to take four sciences. I was intimidated by math, having been through the wringer in high school. None of the core sciences were appealing either. I realize now that I probably could have taken some Geography, Logic, and something else, and that would have been enough. But I got drawn in by computer science.

Truth be told, that story was written a decade and a half earlier.

Picture it: 1982 or 1983, and my dad brings home a computer. A Commodore VIC=20, to be more precise. It was a clunky thing. It had a tape player as its only storage device. But it was fun.

We played a lot of games on that computer, but I got my first real taste of programming. The operating system accepted BASIC commands and you could write a program right on the command prompt and execute it in front of your eyes. Never mind that I didn't know how to save anything that I'd written. Everything was in main memory, and I'll never forget:

10 print "Liam is awesome." 20 goto 10 run

Of course, I was six or seven, so I probably wrote something else, but the premise was there, and I was hooked.

Sean had some programming book, either it came with the computer or he got it at school, but I spent hours typing up the sample programs that were in it. I don't remember anything about how any of it worked, other than when I tried typing out a game that they'd printed out. It rendered ok, but there was no interaction. Honestly, I was probably eight or nine by that point, and the fact that I got enough of it right to even run anything was amazing.

Then, after high school, I finally invested some money in a 286 8MHz computer. It was hopelessly outdated, it didn't run any games or anything like that worth running, but it got me back interested in computers. We'd had a Colecovision ADAM, but I hated that thing. If you didn't load the tape drive or the cartridge bay, it loaded into a word processor. I'll grant that that's something I'd appreciate nowadays, but back then, it wasn't BASIC, so I didn't want anything to do with it.

When I invested some money in a more modern computer after the 286, one that had more than sixteen colours at its disposal, and a whopping 8 MB of RAM, one of the very first things I got was a copy of Borland Turbo C++. I wanted to learn how to program, so I also bought a book. Yes, it was C++ for Dummies, and yes, the stupid thing had the requirement of already knowing how to program in C, so I did the next thing, which was pick up C for Dummies and start learning that instead.

Granted, the book was full of stupid things like Microsoft-specific commands that didn't work when I started sampling Linux, but it got me started down the path to loops, conditionals, variables, and functions. By the time I started the intro to programming course at university, there wasn't really anything for me to learn. But I studied. And I asked a pile of questions. Any time the professor said, "Let's just pretend that it happens by magic for now," I knew I had a question to ask. And he was more than willing to help me figure it out.

I did waver in my commitment to graduating. I struggled pretty mightily with it, especially over summer when I had a job that was paying me right then. Couple that with a suspicion that maybe I wasn't good enough, and you had the fact that I only intended to come back after summer once, and that was the year that I spent taking classes over the summer so I could finish up at Christmas instead of in the spring. By then, I knew my back was basically shot and there wasn't much chance I could do a full-time labour job anymore.

Then there were three very demoralizing years after graduation, when I worked as a Document Control Clerk, then a supervisor. I got what I needed from that job, mainly money to start my life as a married man and experience in an office setting. I struggled, as I failed to qualify for job after job, not even getting an interview, wondering if it would make more sense for me to go back to school for something like millwright training, and just start over. It felt stupid. I'd gone the Student-Loan route through university, and if I was going in for more training, it would be even more time before I could start paying that massive debt-load down, not to mention how much I would have to pay to get certified.

Eventually, though, I got through the resume process, I got into an interview, and I did well. Well enough, at least, that they hired me. Since then, the foot's been on the throttle and, despite a couple of setbacks, I haven't really spent a lot of time looking back. If someone asked me how I identify myself, the third thing on the list would be as a programmer. And if they had something to say about identifying too much with career, I would maybe partially agree with them, but honestly, it is so much more.

Programming is more than a job for me. It's a mindset. It's how I go about solving problems. It's how I come to conclusions about things. Thinking this way got me my second and third mortgages. It helped me to decide to become a contractor and also to become a permanent employee again. I'm not saying I'm an unfeeling computer. Impulse and passion come into it a lot too, no doubt.

I like building things. I like to see them come to life. When all the pieces fit together and it not only works well, but hides the complexity of what's been built from the user, that's a satisfaction I get from very few things -- the two things I identify with before programming providing those. When I'm faced with a problem, I don't panic. When I hit a setback, I don't usually whine. I look for other solutions. And that is because I'm a programmer.

Y'know, in case you were wondering why I do what I do.

Keepin’ Busy

I find myself in the possibly-enviable position of being really busy.

I mean, I've been busy before. It feels like I've been busy since I finished university, with maybe a couple of breaks in there, but now, I've got so much going on, it's almost like I should outsource myself.

First, there's my family. They command my attention, and I would be a fool if I didn't try to give them the best of my time, if not the greater portion of it.

There's the full-time job, working for Gamesys on various projects. That's going really well, and I would let the other work-type things burn if they threatened what I have there.

Then there are the other work-type things. They're what have me excited and scared. I'm worried that I've over-committed, but I'm willing to give it a shot to see what comes of it. Starting on Tuesday night, I'll be alternating between two different projects, in order to both supplement my income and sharpen my skills in technologies that I'm unfamiliar with.

I figure that a month will give me what I need to know, whether this is a realistic thing, or whether I'm kidding myself and I need to pare down. I haven't been this busy in a long time, and I'm looking forward to the challenge.

Why Tuesday? What's so important about Tuesday? Tuesday is the first day in a month where I won't be participating in the summer blog challenge.

Have a good night,


Switch to our mobile site