Usability: Multi-page articles

Ok, we get it. Banner ads are how you pay the bills for hosting your site, and the rate you can charge for them has been dropping year after year, which means you need to show more ads for the same amount of money. Which brings us to the latest trend: articles that could be all on one page, split up over 20 or 30 pages so that the user has to click next every couple of sentences (or even after one picture with a one-sentence caption).

The Page One extension for Chrome and Safari replaces the broken up pages for some popular sites with the single page version.
The Page One extension for Chrome and Safari replaces the broken up pages for some popular sites with the single page version.

Stop doing this.

First off, it doesn’t work. Sure, some people are going to click through the entire article and you’ll get to show all 30 of your ads (otherwise you wouldn’t be doing this). Other people are going to click in, see the “page 1/30”, and click back. You got your one ad impression, just as if you’d put the entire article on one page, but you’ve also ticked off the user, who isn’t going to even think about linking to your content. Do it enough times, and users are likely to start actively blocking content from your site.

Second, it doesn’t work. If you’re irritating a large portion of your users this way, your click-through rates are going to drop, which means the amount you can charge for call to action banners will drop, which defeats the purpose of splitting up the article in the first place.

Third, it doesn’t work. Writing this post, I’m trying to recall what the last banner ad I saw was advertising…and I can’t. I don’t have an ad blocker installed (popups are another story); like most users, I just barely notice them. Even when I do, they’re generally either irrelevant or for something I already purchased – after I bought a cat tree a few years ago, I got advertisements for the model I’d picked (on the site I bought it from!) for the next month. Advertising can be useful to the user (and thus profitable for you) but random Google ads on a page with almost no relevant text probably aren’t.

If you have a 20,000 word article, fine, split it up into pages – that’s actually helpful in case I need to bookmark the page and come back later. But 20 words on a page? Throwing a big picture next to the words doesn’t excuse you for creating a poor usability experience.

Usability: On creating password rules

These days, everyone wants to make it clear that they’re taking security seriously. So they make each user create a password which contains at least eight characters including a lowercase letter, an uppercase letter, a number, a symbol, and some other rule that’s completely different from every other website. Then when you can’t remember your password (I know, I know, we should be using password managers and just remembering a master password) they show you the rules and make you set a new password, which can’t be the same as a previous password. Which means that next time you actually do remember your old password…

Panel from an xkcd comic about password strength.
xkcd is awesome. You should read it.

Minimum password lengths are a good idea. Expanding the character set is probably a good idea. But there’s actually a really easy way to improve usability and not tick off your customers. If I hit the “forgot password” link? Show me the password rules! I know my own thought processes; if I know what the rules are for choosing a password on your website, there’s a pretty good chance that I’ll immediately figure out what my password is rather than having to reset it with something that’s more difficult to remember. You’re not making things any easier for hackers, but you’re making it a lot easier for users.

Project management and consistency in coding

Whenever a team leader position has opened up at work, I’ve been very clear that I’m not interested. While I have no problem with managing people – many of my jobs have involved this – I’m currently focused on improving my development skills.

However, running a project I have no issues with, and for the last few months I’ve been in charge of my team’s web migration project. This has largely consisted of planning out our timelines and helping our newer developers get up to speed on our team’s standards for web development.

"Editing a Paper" by Nic McPhee. Used under Creative Commons license.
“Editing a Paper” by Nic McPhee. Used under Creative Commons license.

I ended up sending one development log back to the developer several times with instructions to put things in the correct order. I don’t mean that the code didn’t work; I mean that I wanted the overridden methods, helper functions, and properties to be in the same order, and functions to be named the same way, as they are in the other classes.  Given that the compiler doesn’t care, why do I bother?

While we’ve been transitioning our legacy code to web, I’ve been taking advantage of the rewrite to ensure that the code is easier to read and update in the future – best practices have come a long way since it was originally written! One thing that makes no difference to the computer, but makes a lot of difference to the programmer, is consistently doing things the same way from file to file. Once you’re familiar with the conventions, it’s very easy both to locate the code for a given piece of functionality and to understand how the logic works.

This is the same reason that we have naming conventions for variables and functions. In C#, if I see a variable name in camel case I know it’s a local variable, while Pascal case means it’s a property. In JavaScript, a function call in came case is for a JavaScript function, while a call in Pascal case is for a C# DataMethod. The event handlers for the save and restore buttons might have different code in different activities, but they’re still named and called the same way. Consistency means that developers aren’t using brainpower to process trivial differences in the code, which makes it easier to focus on the functionality. At a functional level, solving the same problem the same way each time makes it easier to avoid bugs in the code, as we only need to make a particular mistake once.

Paying for Quality

Back in September, I listened to the Soft Skills: The Software Developer’s Life Manual audiobook, from John Sonmez of simpleprogrammer.com, and really enjoyed it. Except for one part, which ticked me off.Soft Skills book cover

In chapter 17, Resumes are BORING, John recommends hiring a professional resume writer to do your resume, under the assumption that this is a skill that you probably have never developed and it’s worth paying a few hundred dollars to get someone who really knows what they’re doing. So far, so good.

Then a few minutes later, when he’s talking about branding, he recommends going to Fiverr and having someone do your logo – the image that’s going to represent you for the foreseeable future – for $5. See the disconnect here?

Now, I have to admit to a bias – my wife is a multimedia designer, and the challenge she faces in finding new clients is exactly this: people who don’t appreciate the difference in quality between a professional designer and the type of person you can hire for $5 off fiverr or craigslist. It’s even worse for websites: too many business owners would rather buy a crappy template site for $100 from someone off craigslist than spend $1000+ for a professional site, even if the cheap site will end up turning away customers in the long run.

I wouldn’t describe myself as cheap, but I don’t like paying more for things than I have to either. When I’m shopping for non-food items for myself, I aim to get them for a least a quarter off. Yet, when I’m deciding what to purchase, quality is (within reason) a larger determinant than price. Why? Quality might cost more up front, but it saves you money (and will make you happier) in the long run. To take a geeky example, I’d rather have one copy of Food Chain Magnate (a VERY good $100 board game) than ten cheap games like Uno, Monopoly, etc; the high-quality game will provide more enjoyment over time.

Photo of the Epicurean garlic press
A $25 garlic press. Well-made tools pay for themselves in lack of hassle.

The same thing applies to services: you can’t (or at least, shouldn’t be able to) get services from an expert artist (or designer, or coder, or any other professional) for the cost of a cheap meal.

As software developers, we expect to be well paid for our expertise; shouldn’t we expect that other people who are also experts in their fields should want and deserve the same?

As professionals, we know that it’s more efficient for a company to hire us at a high rate to create a software package than to hire a college student with enthusiasm and a low hourly rate but without the experience or education to create the product that best meets the customer’s needs. Shouldn’t we express the same judgement when choosing services for ourselves?

Settings Goals in the New Year

I don’t believe in New Year’s resolutions.

It’s almost a cliché that these resolutions never work. We start off with good intentions, and maybe even keep them going for the entire month of January. Then something happens and we miss a day. We get frustrated. Having missed one day, it’s easier to miss another. And soon, the whole resolution is out the window and we’re mad at ourselves for again failing to meet our self-imposed obligations.

New Year's Resolutions

What I do believe in is small goals with deadlines, and systems. The goal “I’m going to finish writing my next book by the end of March” doesn’t work; the result is procrastination until the end of February, and then not doing anything in March due to guilt over wasting the first two months of the year and the impending sense of doom from knowing there’s not enough time remaining to actually finish.

Specific and Achievable Goals

The goal “I’m going to write at least 50 words for my book every day” is much more achievable. It’s not very much work, but more importantly, it doesn’t feel like very much work – how long does it take to write 50 words? It’s also specific – you know exactly what you have to accomplish (write at least 50 words) and when (before you go to bed each day). If you happen to write more than that, great, but as long as you write at least 50 words, you can go to bed feeding satisfied that you have met your goal. Eventually, this becomes a habit, so it doesn’t even use up your limited supply of willpower – writing 50 words is simply part of your daily routine, like brushing your teeth and (unfortunately) checking Facebook.

For the last few years, my goal has been to finish my PhD, which meant that I needed to finish writing and defend my dissertation. This is essentially the same problem as the writing a book goal above, with the added strain of being mentally challenging and requiring a lot of concentration. I often found myself looking at the desired end result – completing the dissertation – rather than setting small, specific goals, such as proving one lemma, and the result was that I never wanted to work on the dissertation; it simply seemed too overwhelming. Fortunately, I had an external deadline – the pending expiration of my earliest credits – which finally forced me to sit down, finish the dissertation, and complete the degree. So that was my big accomplishment in 2015 – after much procrastination, I finally completed one of my lifelong goals.

My Goal as a Developer

This year, I’m formalizing something I’ve been working on for a while – developing my skills as a programmer. I’ve been writing code professionally for the last five years, and lately I’ve moved into more of a leadership role on my team. This year or next, I expect to be promoted to Senior Software Developer, but I don’t yet feel like a senior developer; while I no longer feel like I don’t know what I’m doing, neither do I feel like an expert programmer.

The things I’ve been doing to develop as a programmer are not wrong – actually, I’ll be continuing to do them. Obviously, I’m getting more experience by going to work and coding every day. I read a lot – I’m currently working on Code Complete 2, which I somehow managed to avoid until now – and I recently signed up for a Pluralsight subscription. In other words, I’m getting the two things I feel like I need more of – knowledge and practice.

 

Code Complete 2 book cover

The problem here is that while these are good practices, they’re not specific. About three years ago, I picked up a copy of CLR via C#, and really enjoyed it. I picked up a better understanding of a few things that I was able to apply at work. One thing I never did, unfortunately, is finish the book; one day I just stopped picking it up, so I never got to some of the fun topics towards the end. Similarly, I had a free trial at Lynda, which I never really got around to using. I’m finding that I need deadlines to keep myself working on the things that I want to do, but that are less fun than, for example, watching Doctor Who or playing Tichu, or less urgent than feeding the dogs and doing the dishes.

So for this year, I’m going to give myself some recurring deadlines. They won’t be hard to keep up with – I don’t want to just miss one in January and then give up on the whole thing – but they will meet the following requirements:

  1. They will be specific. I will know exactly what I need to do, and when I need to do it.
  2. They will move me towards my goals. The goals might be nebulously defined (what does it really mean to be a better programmer?) but the deadlines will be for things that will point me in the right general direction. It might be more accurate to say that I’ll have mini-goals that will move me towards my main objectives.
  3. They will be small, to the point that it will be easier to do them than to berate myself for not doing them.

So, let me first start by defining my objectives for 2016. I’ll choose two: one long-term objective that’s work-related, and one short-term objective that’s not.

Objective 1: Finish planning for my trip to Europe. I’m taking sabbatical in a few months, and I haven’t yet figured out where I’m going to stay or exactly what I’m going to do in London. Thus, the first things I need to do to meet this objective are:

  • Select and reserve a hotel.
  • Determine how to get from London to Stonehenge. Make any required reservations.
  • Buy Oyster passes so we can get around.

None of these individually should take much time, but none feel urgent either – the trip was scheduled half a year ago, but they remain undone. So, this coming week, I will have the following deadlines:

Monday: Narrow down my hotel selection to no more than three (I already know the section of London I want to be in) and get my wife’s preference.

Wednesday: Make the hotel reservations. Determine how to get from the hotel to Stonehenge and make reservations for that.

Friday: Determine the rest of our transportation needs (most likely, this will be Oyster passes to get around London and then Chunnel tickets to get to Paris) and make those reservations.

Once these are done, I’ll set new deadlines for other things I need to do, like figuring out how to keep my devices charged and whether I can pack clothes for two weeks in a carry-on. Now for the long-term goal: becoming a better programmer.

Objective 2: Improve my programming skills.

The problem with this objective is that it’s hard to measure; there’s no test that says “you are 85% of the way to being a rockstar programmer!” Instead, I want to implement a system that will have me doing things which will tend to increase my programming abilities.

1) I will attend at least 10 development meetups or conferences in 2016.

Until 2015, I’d never been to a development meetup. This is partially because it’s inconvenient to get anywhere from where I live, partially because I’m very hard of hearing and tend to avoid group activities, and partially out of inertia. In 2015, I attended That Conference and one meetup each from the MADdotNET and Madision Mobile .NET developers groups and enjoyed all three, so this year I’m going to try to make it a monthly thing. At some point in the future I’d like to start speaking, but I don’t know yet what I’d like to talk about.

2) I will start updating my blog again.

I started whatwilliamsaid.com quite a few years ago, but I’ve never really been all that interested in blogging so I haven’t updated the site consistently. I’m going to start doing it regularly, for two reasons. First, explaining something is a great way to clarify your thoughts about it. Second, I’ll need to find things to write about; since the blog is going to have a software development focus, that means getting in-depth about lots of topics so I can write about them. For this goal, I’m going to say that I’ll spend a half hour working on the blog each week, and if a post is ready to go I’ll publish it. Further, I’ll publish at least two posts each month.

3) I will post at least one book review each month.

I’ve been posting reviews at Vulcan Ears Book Reviews since 2010, but never as much as I’d like, and I also don’t get as much reading time as I’d like; last year, I only posted two reviews. This year, I’m going to read and review at least one book (which may or may not be a technical book) each month; this will force me to stay on track with my reading, particularly since I have an easier time reviewing the type of book I should be reading (programming books) than the type of book I just read for fun (science fiction).

So those are my goals for the new year. They do sound a lot like resolutions, but have two advantages: they’re clear and specific, and they’re focused not on the end results, but on the concrete steps that I need to take to achieve my desired results. Next December, I won’t have a piece of paper that says I’m a 13% better programmer, but if I follow the plan, what I will have is more education and experience that will better equip me to meet whatever goals I might set in the future.

Stupid Computer Errors: Black Screen on Startup

This evening my wife’s computer was being annoying. It would start up normally, display the Windows 7 splash screen, and then go completely black except for the cursor, which would move around normally. Control-Alt-Delete and Control-Shift-Escape did nothing.

Restarting in safe mode, I was able to get into the Task Manager, determine that explorer.exe was not running, and start it . So that defines the problem, but why was explorer.exe not running on startup?

A Google search pointed to a registry issue. There are a couple of keys that can (somehow) get messed up and will then keep explorer from starting. Both are in the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon folder; however, I saw one person say that he needed to do the same fix in HKEY_CURRENT_USER.

The key “shell” needs to be set to explorer.exe and the key userinit needs to be set to userinit.exe. Checking the registry, I found that shell was fine but userinit had somehow been set to “C:\Windows\system32\userinit.exe,” (with a comma at the end); resetting it to just “userinit.exe” fixed the issue.

Interviewing with Microsoft and Epic

For a while now, I’ve been meaning to write about my interview experience with Microsoft last year; since I interviewed with Epic recently as well, I figured I’d talk about both of them. I will not be disclosing the interview questions (and will delete any comments asking what they were), just the general format of the interviews.

I found out about the Microsoft ones when CSU sent out an email asking for students who were interested in applying for a job working on Bing maps, which are developed in Boulder. The interview at CSU was pretty short: two questions! In each case, you had to psuedocode out an algorithm to solve a problem, improve it to linear time, and implement it in the language of your choice. Simply solving each problem was simple enough, but getting it down to O(n) required a bit of insight. In fact, the interviewer told me that most people didn’t get past the first problem!

Although he said that I was the best interview he had that day, he still gave me their recommendation to read Programming Interviews Exposed, which I promptly picked up from Amazon; he said that most of their questions are variations on what’s in the book. While I knew most of it already, I thought it was a great review of basic concepts (linked lists, trees, heaps, concurrency, etc) and recommend it strongly to anyone wanting to brush up on standard algorithms.

I was told they’d contact me quickly to set up an on-site interview, but it actually took over a month. I had a full day of interviews, each of which (except the lunch interview and the final interview) involved working through a reasonably complex programming problem. At the end, I was told by the last person I talked to that they felt I’d be a better fit in R&D rather than the codemonkey position they had open (not that they called it that, of course).

Then I spent the next two months ignoring requests to submit documentation to get reimbursement for my plane ticket to Boulder.. too bad they didn’t just offer to pay for gas!

Also last year, I ended up going to a CS job fair, where I gave my resume to an Epic recruiter. I’d never even heard of Epic and gave it no more thought until they emailed me for a phone interview. I’m not fond of those – since I don’t hear well, phone interviews don’t normally go well for me – but I spent about 45 minutes talking with one of their people, not really expecting anything to come of it.

A few days later I  got an email that they’d like me to continue through the process and would be sending a test to CSU for me to take. Unfortunately, that test never showed up, so a few weeks later they sent another one. The test format was simple: solve the programming problems in any language you like, including psuedocode. There’s no time limit, but you still have to record your time and it makes up part of your score. The problems start off very easy (I think I spent about 4 minutes on the first one) and get progressively harder; one of them was similar to a practice problem in the programming interviews book I mentioned above, which sped me up a little. I think the test took a couple of hours.

The school sent the test back to Epic, and a week later I got an email that they had received it and would contact me within two weeks if they were interested in moving forward. A couple days later, I got a voicemail from someone in HR letting me know that I’d be getting an email to schedule an on site interview.

I flew out on a Wednesday and spent Thursday morning interviewing. The process is set up largely so you can get an idea of what is expected; while there were four or five interviews, plus lunch, mostly it was people telling us about the company and their jobs, plus a technical interview with a coder and a final interview with HR. At the end of the interviews were three more tests: a 60 second test where you had to answer as many questions as you can before time ran out (I just barely got all twenty), a math test, and a programming test using a fictional programming language. Epic makes a big deal about GPA (they claim to want, IIRC, a minimum 3.2/3.5/3.7 for undergraduate/graduate/postgraduate work) but I suspect it’s the tests that make the biggest difference in you getting an offer.

After that, I had a few hours free to explore the campus (which is beautiful – I plan on taking some photos once I have a little free time) and told me I’d hear back from them one way or another within the next two weeks. When I woke up on Monday I had an offer waiting for me, and I started at the beginning of January.

Dealing with Spammers: A Modest Proposal

In 2009, it was estimated that spam would cost the world about $130 billion, $42 billion of that in the United States. While technological measures are getting better (for example, Askimet for blog spam), it will always be an arms race between the spammers and the anti-spammers. What can be done?

A significant percentage of email spam is still the Nigerian 419 scam, named after the relevant section of the Nigerian penal code. (The scam actually precedes email; it used to be sent by post!) Everybody’s gotten this one: a rich person died, and concerned people involved need help to get the money out of the country. If you’ll just provide your bank account details and hold the money for them temporarily, they’ll cut you in for a fat percentage.

Since so much spam originates in Nigeria, we have a simple solution: why not transfer ALL spammers to Nigeria? Round up anyone responsible for email or blog spam and give them a one-way ticket to Africa, with a death sentence if they return. Then cut Nigeria off from the internet.

Cruel? Maybe. But isn’t it worth it to eliminate the spam problem once and for all?

Megamind

Now I remember the other reason that I never go to the movies. 2 tickets, one popcorn, nachos, and a drink: $37!

The first reason, of course, is that in the past it’s been almost impossible to find a captioned showing. Lately that’s been getting a lot better; while you still can’t find a showing of anything with captions the week it comes out, it’s usually possible to see all the top movies.

So today we went to see Megamind open captioned…and of course, their machine was breaking down and the captions were extremely faint. You could still read them fine when the screen was dark, but they were almost invisible when the screen was light :p

Anyway, we enjoyed the movie, though following it was a struggle for me due to the captioning issue. We never got around to seeing Despicable Me (although I have it in our Netflix queue) but I’m a big fan of Dr. Horrible. There are no really big surprises in the movie, but it’s a lot of fun.

Adding line breaks in WordPress, and stuff like that

Found a nice little plug-in today that gets rid of an annoyance in WordPress.

Normally, if you try to add extra vertical space, either by hitting enter in the visual editor or by adding <br /> tags in the HTML editor, WordPress just strips them out, so you have to do some extra work to get them to stay in. What I just found out about is a plugin called TinyMCE Advanced; one of the options in it is to turn off that behavior, which it does by replacing your <br /> tags with <p><br /></p>. Sure beats doing it by hand!

It also lets you add more buttons to your toolbars, for things like tables, non-breaking spaces, justification, etc. I’ll probably be coding a WordPress site for the charity that Brit does the website for in the next few weeks, so this should be a useful thing to throw in to make it easier for them to edit their own posts.