Steve Freeman wrote an excellent article on "Bad Code":

Call options are a better model than debt for cruddy code (without tests) because they capture the unpredictability of what we do. If I slap in an a feature without cleaning up then I get the benefit immediately, I collect the premium. If I never see that code again, then I’m ahead and, in retrospect, it would have been foolish to have spent time cleaning it up.

The analogy is especially poignant because we've all been in the situation where our time is spent fixing expensive bugs in old code. He is exactly right. Bad code is like a call option: an infinitely risky choice.

Why would you ever sell a call option?

So then, why do some people sell call options? Or to carry over the analogy, when would you write bad code?

Selling an option is like entering into a contract with someone that dictates they can buy two super bowl tickets from you in 2 years for $3000 (tickets often sell for around $2000 each). If you can get the tickets for less than $1500 then you'll make a profit. If however, the tickets skyrocket to $5000 a piece when they decide to buy you would lose $7000.

You sell a call option when you know (or expect) the value of the product will go down. 1 Meaning you SELL the contract now for a price because you believe you can BUY the product for a lower price at a later time. (You sell Super Bowl ticket contract for $3000 when you are very confident you will be able to get them for less than $1500 a piece.)

We pay for our code with time and the lost opportunity of additional features. If you have to spend time fixing buggy code you can't add new features.

If you are writing code that is crappy, it means you think you’ll have more (cheaper) time later to write better code. You are selling your product now because you are confident you won't be spending time on new features later. Is that true? Or are you making a bad judgement call?

Are you unintentionally betting against the future of your product?

Some contractors may be working on a one-off product. In that case, it doesn't make sense for them to invest heavily in well written code. They sell their unwritten work for a set price, and then build it for as little as possible.

However, if it's a product for which you have long term plans, and future features to add, bad code is the wrong side of the table. When we bring on users then our time will be more expensive, not less expensive. When we our product has paying customers we'll have stricter requirements on how we spend our time, not looser requirements. If you believe in the future of the product, you shouldn't write bad code.

There is, however, a place for technical debt.

Debt as a tool is simple. Imagine you could buy an app for $20,000 that makes $10,000 a year. Would you do it? Maybe not for cash. But what if you could buy it with a bank loan? If the terms of the loan allowed you to pay off the loan in 5 years, you could grow the business and get a reasonable return on a very low up-front cost. If you believe that the business will grow, you're willing to take on the $20,000 risk with the expectation that paying off that debt will be feasible.

You incur debt when you expect the value of what you're buying to go up. Meaning you BUY the contract now because you believe you can SELL the product for a higher price later (over time). It’s important to note that the technical debt I’m referring to isn’t going back and rewriting old code. You may have a little bit of refactoring later, but true debt is something you don't pay for now.

It's entirely possible to fake out or leave features unfinished without writing bad code. For example, management may want to include "delete user" in the minimum viable product. You may buy that feature with debt (not actually paying for it) by including an email concierge service to delete a user. (The app enables the user to send an email requesting to remove a user and you manually delete the user rather than writing code to automate it). You are selling the feature for a premium because you didn't pay for it yet, and you can write code that accomplishes the feature later using the profit you captured in the period the feature was manual (i.e. hiring more developers).

You may look at your product and find features that you can purchase with debt (meaning you don't actually pay for it today, but offset it to the future). If you believe that in the future your team will grow and you will have a greater ability to spend time on features and performance, you may consider faked or manual solutions that come with very little up-front code cost. Be cautious: too much debt can eventually bankrupt a product. However, when used wisely debt may allow you to move faster than you could otherwise.

Steve Freeman was right, we don't know the future, so we should be far more careful with the code we write. Bad code is a blank check to be cashed in the future.

However, true "Technical Debt" actually is a valuable tool that developers and product managers can use in order to work around implausible delivery dates2.


  1. I'm aware, and maybe you should be too, that most investors that sell naked call options simultaneously hedge their bets by protecting some of their downside with another call option at a higher price. This may carry over into where you may write better code in another area of the app, or you may hire another developer to go back through and write tests or fix bugs in a second pass. 

  2. That's actually Freeman's term, not mine. 

If we're honest code style (like the famous 'nested else') is silly little problem that we all care way too much about. Objective Clean is a Mac app makes it super easy to fix. My development team decided to take a stab at keeping style rules using the app and we're loving it.

The simple purpose of the app is to set and enforce rules for code style.

On my last team we spent hours every week making each other go back and fix code style faux pas. With Objective Clean my team was able to go through all of the rules (you do it on their site) and make sure we could agree. The app doesn't change your code for you. It simply nudges you in the right direction with either compiler warnings or errors (you decide which). One of our developers went through the code and, thanks to the app, cleaned it all pretty quickly.

I highly recommend the app. It's available in the Mac App Store. But I have 5 promo codes to give away. I'll give it to the first 5 people to email me. You're going to love it.

The Creative Process

You know Kibuishi nailed it when he said: "Creative process: 1) This is going to be awesome 2) This is hard 3) This is terrible 4) I'm terrible 5) Hey, not bad 6) That was awesome"

You know he nailed it because it received over 7,600 retweets and over 4,600 favorites. And you know he nailed it because you personally have felt the same in any creative endeavor you've attempted. It seems to be true for any skill in art or performance. It seems to be true for any knowledge in a domain or trade.

If you've ever tried then you know it's true for learning to program.

This is going to be awesome

I've had countless friends and colleges come to me and ask me how I did it. They say: "It would be so cool to learn how to make iOS apps. I have to take some time to learn. I wish I was there."

Most people never even have that inclination. They don't ever find themselves thinking "how cool would it be if". If you're here, you're already a step ahead.

This is hard

It's hard to even take the time to sit down and attempt to learn. We all say we're going to write more. Or design more. Or take more pictures. When you plan to learn some new skill it's hard. It's hard to find time and it's hard to get it right.

It's impressive when you finally do it because of the millions of people that chose to watch Breaking Bad while you were breaking your app.

This is terrible

Yup. You heard me: breaking your app. Because whatever you are trying to build, it sucks. It isn't very good. We've all been there. And when you are pushing the boundaries of your skill something is going to break.

I have clients and co-founders ask me frequently for an app portfolio. I don't even want to show them half of it. Why? Because it's terrible. You remember the Ira Glass quote:

All of us who do creative work, we get into it because we have good taste. But there is this gap. For the first couple years you make stuff, it’s just not that good. It’s trying to be good, it has potential, but it’s not. But your taste, the thing that got you into the game, is still killer. And your taste is why your work disappoints you.

Your work sucks for now. You know it. And I know it.

I'm terrible

There is a risk is that you'll to start thinking it's you that sucks instead of just your work.

You think it's you. And then as Glass points out, " A lot of people never get past this phase, they quit." They quit because even a good artist can see that what he's building is terrible and start to think of himself as terrible.

You're not terrible. You just need to keep going. Build a ton. Write a ton. Take a ton of pictures. Eventually you'll start to see that glimmer of hope that you don't suck.

Hey, not bad

This time will come soon. You're going to get to the big #5 in Kibuishi's list. This is when the world opens up to you.

Then you get to the point that you start solving problems on your own. You start smoothing the edges of the work you're creating. You start doing something that's completely yours.

More importantly you start feeling proud of your work. It's something you feel like you can share. This is where the flywheel starts working.

When you share with others you're going to learn and grow even faster. So as you start to feel good about your code and share it with others you'll start to get some amazing feedback and advice from people you respect.

That was awesome

I had an amazing designer pull me aside yesterday and show me something cool in an app. It was small but it was really well done. He asked me: "how did they do that? What do you need from me so that we can do that?"

You'll get to this point. Someone is going to look at your app and say: 'how did you do that?' Heck, you're going to look at your app and say: 'how did I do that?'

Over and over

We all go through these steps every time we push ourselves to be something more. I can't tell you how many times I've gone through all 6 as I learned to code.

In the end it's simply about growing. I want to say "That was awesome" as many times as I can in one life.

Going for Gold

What I want

Let me start with a simple fact: I want the golden iPhone. I was depressed on launch day when, only 80th in line, I didn't get my new gold colored device. In fact, it was the first launch day I wasn't rewarded for waiting in line with a new iPhone. It was a bitter pill to swallow.

Even more bitter was the vocal minority on Twitter that began squeeling as if only someone that cared about showing off that they had the latest (or a belly dancing gypsy) would prefer the color of gold. Hmmm?

This isn't the first time I've had someone make fun of my iPhone color choice. I wanted the white iPhone 5. I knew it from the second I saw it. Gorgeous. We're still talking about a silly phone; but it really was the most beautiful silly phone I'd ever seen. Everyone mocked me:

You seriously got the white one?

Yes. I seriously ordered, and loved, the white one. Within a year, every one of my friends had told me they wished they had opted for white for one reason or another. The most common reason being the way the black bevel showed scuffs too easily.

We'll see what they say about gold. But I'm not holding my breath that they'll pine for a golden iPhone. It's all about fashion, and we often disagree about fashion:


What is the real reason

Guy in line: "No one is going to get the gold. There will be plenty."

Me: "Which color do you want?"

Gil: "Gold"

Me: "Everyone is going to get the golden iPhone."

Gil: "Everyone is bashing on it."

Me: "Ha. That 'everyone' is a minority."


17 year old brother: "Why is gold so popular? Because it's new?"

Me: "Which color do you want?" (He's ordering one today.)

17yob: "Gold."

Me: "Why do you want gold?" (My brother is very fashionable.)

17yob: "I think it looks the best. I like the golden ring around the home button. It's the coolest style."

Luxury and Fashion

The iPhone is a fashion accessory and Apple wants to be a luxury brand1. It seems to me that being fashion forward means pushing trends just a little too far. To be truly fashionable sometimes one needs to be a bit ostentatious. Going gold was certainly considered a bold (and awful) move by tech bloggers, because they saw it as too ostentatious. However, I don't thing gold is ostentatious today.

I asked my wife what she wanted for her birthday (coming up on Thursday). She wants a gold watch. Ashley is always dressed very conservatively. She doesn't wear flashy styles. So I was surprised at first to hear that she wanted something that sounded ostentatious.

It sounded ostentatious until I persused pinterest for example watches. Check it out and you'll see there has been a major influx of golden jewlery (i.e. watches, bracelets, earings, necklaces, and even purses). This is what is in style, it is what 'normal' people are going to choose for their wedding rings and everyday jewelry.

Platinum and silver have become commonplace. Everyone has silver or white-gold colored wedding rings, bracelets, and necklaces. The color doesn't look luxurious anymore. It doesn't look elite. Fashion is about standing out, and luxury is about standing above. Gold is the luxurious color. If you don't believe me, just go visit the strip in Las Vegas.

Newness isn't enough

If you're someone mocking me and my golden iPhone you probably don't wear the current fashions from broad market clothing designers (you may even mock them).

  • Rolled up skinny slacks or jeans
  • Sock-less boat shoes
  • Bright colored pants
  • Short shorts (prep-length)
  • Geek glasses with no prescription
  • A fedora

Some of you probably wear some and eschew others of those styles. Maybe you have prep-length shorts, but think fedoras are a joke.

This is not an extreme list. They are 'middle of the mall' styles. It's nothing you wouldn't see in a J-Crew order catalogue. For that matter, wouldn't you expect to see the golden iPhone (rather than the silver or space gray) in a J-Crew or Banana Republic catalogue? That's not a department store designer; that's a 'middle of the mall' clothing store.

I fully admint that for many customers the golden iPhone represents newness. If you want to show off that you have a new iPhone the best way is to purchase the gold colored version. You may want the newest phone. You may even want to show off that you have the newest phone. But if you aren't willing to take a step into forward in fashion, the newness probably isn't enough to make you buy an iPhone color with (you deem) no sense of style.

If you were thinking the golden iPhone is in-style and you'd like it for your device but you are resisting it because you don't want to be one of those people that are getting it because it's new, well that would just be silly.

Subtlety was important

Apple needs to sell a ton of iPhones2. They are in a business that is attempting to reach a broad market with a luxury brand. This means they need to be subtle while also being fashion forward. Being too ostentatious will simply turn off the majority of their customers.

The new iPhone 5s is actually more of a muted gold or 'champaigne' color. I know when the rumor mills were cranking the mockups were all a gaudy-dehydrated-urine yellow. If the actual gold iPhone were a deep-bronze color I wouldn't want it, and neither would (I believe) 80% of the people that are waiting an extra 2-3 weeks to get their new device.

The color matters and the style matters. Apple didn't release something out of style to which mindless sheep are flocking because it's new. Apple released something in-style to which millions are flocking because it's attractive.

The golden iPhone 5s was made for customers that do have a sense of style - the same sense of style as the iPhone 5s designers3.


  1. 1) If you don't think a $600 phone or $1000 laptop is luxurious you are in serious need of a broader world view. 

  2. 2) 9 million opening weekend will just about do it. 

  3. 3) Yes, I realize that I'm effectively claiming that I 'have a sense of style'. I'm assuming that you believe that you have a sense of style as well. If you think the golden iPhone is ugly we can assume, for better or worse, that the designers at Apple disagree with your sense of style.