Design Candy-Machine Interfaces

This is based on Chapter 5 of the same name in Writing Solid Code by Steve Maguire.

Once upon a time Steve came across a candy machine that offered up Grandma's Peanut Butter Cookies and jalapeno-flavored bubble gum (among other things). Unfortunately the sign by the cookies read "No. 21, 45 cents". And Steve found himself plopping in his quarter and pressing 45 instead of the 21. And he did notice an odd flavor and texture to Grandma's cookies because he'd accidentally requested the gum in slot 45 not the cookies in slot 21. Oh how he wished the designer of the vending machine had just taken a bit more time and associated letters with the slots to that the cookies would have been "BA, 45 cents".

Moral of the story: When designing interfaces, try to vision yourself as "The Candy Man" (great song, great performer) and make sure you make it easy for your clients to get what they want, cookies or gum.