Friday, January 03, 2014

Solitaire, Zen and Engineering

The game I play the most is Solitaire on my iPad.  I play it when I’m waiting for a flight.  I play it when I’m waiting for fall asleep.  I play it on a flight, when I’m too tired to read anymore.  I’ve played thousands of games and have nearly perfected my ruleset for winning (the percentage of Solitaire hands that can be won from randomly sorted decks is ~ 85%).
After years of playing, Solitaire has also started to reinforce, in a visceral way,  something about engineering, and possibly life in general.  It’s reminded me the benefit of focusing less on the outcome and more on the steps in between.  It reminded me of a book about Zen and motorcycles I read 30 years ago and it’s closing a long, old circle.
In Solitaire, the goal is to completely sort the cards into the four “foundations”.  Decisions made on card placement and the initial sort determines how easy, hard or impossible the goal is too reach.  In addition, my iPad Solitaire game has an option to only deal hands that are known winners, which eliminates the ~ 15-20% of the deals that are impossible to solve.
I’ve gone through several phases in my attitude and approach towards the game:
- Stage 1: Playing to win and failing frequently.  I played randomly and was quickly frustrated with getting stuck and would give up quickly, but I was delighted when I won.
- Stage 2: Mastery and the pursuit of winning.  I cared about winning and would play moves into the thousands to win.  I developed a deep set of rules about moving cards, which resulting in a ~75% winning ratio.  After a while, I found this pursuit of winning, percentages and winning streaks led to much frustration and I gave the game up for awhile.
- State 3: Playing only winning hands.  After I came back, I only played the “known winners” option.  After this, I never lost a game.  I racked up hundreds of wins in a single streak.  Sometimes a deal was particularly hard and it would take days to win.  After months of this, I became bored and frustrated again and gave the game up.
- Stage 4: A few months ago I returned and started playing the random games again.  At this point I no longer care about outcomes, but enjoy the flow of the game.  I know I can win every solvable game.  I explore every known “path” to winning a hand and if it becomes apparent that it’s an impossible hand or if I feel the effort to win is not worth it, I’ll “surrender” and deal a new hand.   I’ve found that I enjoy the game far more and unlike the previous experiences, find it quite relaxing and engaging.

This last stage has led me to rediscover something valuable outside of Solitaire, related to engineering.  When I build a device or write some code, I get very engaged in making it work.  When this device or app refuses to do what I want, I get frustrated.  This leads me into a cycle of pounding away at all the possible solutions, which leads to more frustration at why a fix doesn’t work.  I’ve always felt that my tenacity at solving problems and dealing with any level of frustration was a strength (I’ve broken a few keyboards).
But my recent experience with Solitaire has led to me try a different approach.   Why not embrace the failures not as failures, but opportunities to learn about what the world is telling me?  Recently, I tackled a problematic Arduino/Xbee data transmitter device that has been intermittently failing for over a year.  Instead of trying to rush to a solution, I spent more time characterizing the problem in a playful way.  I decided to learn more about radio transmission, antennae impedance and trying out all sorts of ways to characterize the problem.  I definitely had fun learning more deeply about how the Xbee and the Arduino libraries for it work.   At the end of this playful endeavor, the solution sort of “popped up” (it actually interrupted the fun).  This time it wasn’t the relief of something working, it was more the feeling of “well, of course that’s the way it should work”.  The reward had transferred from the solution to the path of learning, which produced the solution.

This reminded me of books I read decades ago (like “Zen and the Art of Motorcycle Maintenance”), which described “mindfulness”: of being in the moment.  Although I understood the concept of mindfulness from reading about it, I hadn’t tied it to engineering or living.  

I’m not a Zen devotee (although I did take my little 550 cc motorcycle cross-country after reading the book) and I don’t adhere to any religion.   I won’t be shaving my head or donning robe anytime soon, but I will be focus on exploring this state more.