ThemePartner, Professional Joomla! Business Templates

Theo

How Playing Poker Can Make You a Better Programmer

September 5th, 2010 at 11:55 AM CEST in Miscellaneous

Does the following scenario sound familiar? You are struggling to look through a badly commented piece of spaghetti-code in search of a nasty bug. Just when you think you might have stumbled upon some relevant code, your boss storms in and asks what is taking you so long to deliver him the critical set of data he requested last week (which you promised to deliver even though you didn't have time for it). You make up some excuse about a broken coffee machine while trying to hide your fear of getting fired over this, after which your boss storms off again looking 'not angry, but disappointed'. Discover in this blog by ThemePartner how playing poker will help you prevent these situations.

Poker cards

Photo credits: Tiffa Day

Learn how to read people

In the poker scene, it is a well known fact that you're not only playing the cards of your opponent, but you're also playing the player itself. In my opinion, the same fact applies to an office environment. When you're trying to get a raise, see if your joke at the coffee table might have insulted your boss, or persuade your co-worker to get you a cup of coffee, reading people is a vital skill. Playing poker will make sure you'll interact with a lot of people, which should sharpen your focus for subtle hints in their body language, facial expressions and verbal behavior. If you're interested in taking this skill to the next level (possibly even before you sit down at a poker table or behind your desk), I would recommend reading the following two excellent books on body language and facial expressions: What Every BODY is Saying and Unmasking the Face.

Play tight-agressive

Most poker books will advice you to play a 'tight-agressive' style at the table. This style involves folding many hands and playing hard on the hands that are worth playing. This advice holds as well for a programmer. When you are a self-employed programmer you can easily bounce off any work you do not think will be enjoying, profitable or challenging enough. As an employee, this situation is slightly more difficult. Then again, why not show initiative at the conference table by convincing the management that (in your opinion) the new function they want you to code will be a complete waste of time? As long as this opinion is based on solid arguments, they might actually drop this unwanted project. Just like in a tight-agressive style decisions are made based on many factors including your hand, your stack and your bankroll, decisions whether or not to take a programming job should be based on the largest amount of factors available as well. Taking only the best (or least bad) projects will ensure a more enjoyable time spend programming, and most likely better code as well.

Train your multitasking skills

Playing poker (especially online) will involve heavy multitasking. Some players will play over 16 online poker tables simultaneously, which not only requires great concentration and skills, but also a lot of multitasking ability. In a common office environment, interruptions happen around the clock. A text message from your wife reminding you to pick up the kids after work, a co-worker asking you to have a look a the latest lolcat, and don't forget that never-ending stream of Tweets coming in. To survive in the modern office jungle, multitasking is a vital skill just as much as at the poker table. Some differences exist between persons in their ability to multitask. For example extroverted persons (to which about 60-70% of all people belong) are mentally more capable to handle more things at once, and women are said to be genetically better at multitasking than men. Several scientists have stated however, that it is possible to train your multitasking abilities. What better way to do that than by playing poker?

Build discipline

Playing good poker requires a great deal of discipline. Especially in a game of no-limit poker (where every hand can be your last in this game), it is essential to have your emotions under control and be as disciplined as possible. Great discipline in programming shows itself in properly commenting code, writing unit tests for your code, filter your input and escape your output, to name a few. An often overlooked factor of discipline is keeping yourself in one piece. Virtually ever programmer I know has (small or larger) physical complaints of some kind, yet very few have break reminder software running to make sure they take proper breaks. A great piece of software I can recommend as a break reminder is Workrave It is a light-weight program, that is highly customizable and totally free!

Use a proper strategy

Without a proper strategy, you will fail both as a poker player and as a programmer. If you have a solid plan behind what you code or the poker games you play, that will make sure you can analyze the results that are produced, because they will be consistent. This will enable you to learn and improve your future games and codes. Amazon lists over 30.000 books related to poker and even over 120.000 related to programming. The amount of articles on the internet on both topics is virtually unlimited. Therefor one cannot say that the literature to base a solid strategy on wasn't available. The analytical mindset that will most likely get you far on the poker table, will be 'profitable' for a programmer as well. Rather than running around like a headless chicken when a problem arises, you can calmly analyze and solve a problem when you have a predefined strategy in place.

Football strategy

Photo credits: Avinash Kunnath

Analyze your hands

To become a great poker player or programmer, it is important to analyze your output (either played hands or produced code) on a regular basis. For both the poker player and the programmer there are tools for doing this (semi)automatically, so you do not have to worry about it constantly. While the poker player can use tools that will analyze their hand history, programmers can use code validators to see if their code validates against known best practices. Well known examples of this include the W3C validator and JSlint. Programmers have another trick up their sleeve, but this one require some effort up front: unit tests. When proper unit tests are in place, they can automatically analyze code for consistency, unwanted outputs and many other problems.

Standing on the shoulders of giants

Both the global poker and programming level has risen sharply over the past decades. As noted before, virtually unlimited material is published on internet and in books. Learning from others will enable you to prevent mistakes and improve your game. Just like poker players have the 2+2 forums, programmers can learn and share their knowledge on forums as Devshed and Digitalpoint. By sharing your own knowledge and learning from the knowledge of others, you are essentially 'standing on the shoulders of giants', which enables you to reach greater heights in your level of programming.

Bluff

And when all else fails, you can always use your newly acquired bluffing skills to bluff yourself out of trouble!

Follow us on Twitter

User Comments

No comments yet

Add comment

Add a comment

*
*
*

*

 

Buy 2 Templates, Get Your Third Free!

Buy 2 Templates, Get Your Third Free!

By popular demand we've introduced a way to purchase multiple templates, at a discounted rate! If you add any three templates to your shopping cart, you'll only have to pay for two!

Blog categories

Conferences

Upcoming conferences

Past conferences

Reports on past conferences