assert_not magic?

Ryan Palo
        def test_code_isnt_magic
          code = [:ruby, :python, :javascript, :html, :css, :bash]
          assert_not code.any? { |language| language.magic? }
        end

        # A programming blog by Ryan Palo
        
Scroll down...

The Programmer and the Sea

Nov 8, 2018 Buy me a coffee Buy me a coffee

This story originally published by Simple Programmer. Cover image courtesy of the Simple Programmer staff.

Learning to code is a journey. Recently, on a trip to Morro Bay, California, my wife and I went stand-up paddleboarding, and I noticed a lot of similarities between paddleboarding and programming. So, the rest of this article is a metaphor for the developer journey.

In the interest of clarity, I’ve labeled a few of the key parallels with reference numbers. At the end, each of these reference numbers has a short, concrete description of the idea behind each metaphor. Of course, like all (hopefully) good literature, part of the value is the unique experiences the reader brings. I highly encourage you to connect other similarities to your own life and share them.


As we walked down the harborfront, some of the locals were already out on the water. It was a beautiful day; the sun was out, and the bay was smooth as glass. They were gliding around, weaving in and out of the anchored boats, and paddling with grace and ease.

They were stand-up paddleboarding. Fundamentally, a paddleboard is a bigger, flatter surfboard that you stand on, and you use a long kayak-like paddle to paddle yourself around for sport or relaxation.

We looked out over the bay at all the people tooling around. Some had simple, beautiful boards. Some had what looked like very complicated setups, custom paddles, and extra-fancy rigs—looking at these people, I wasn’t sure if I would even be able to get started. It looked like there was so much stuff that we needed to have and so many things we needed to know. It was hard not to be intimidated (1).

Even still, it looked like fun, so we headed down to the waterfront to a kayak and paddleboard rental place that we’d used before (shoutout to the folks at Rock Kayak). I needn’t have worried about not having what it takes to get started.

The people there were used to dealing with people like us: full of excitement and drive and empty of any knowledge or skill. After signing a couple waivers, they gave us a quick rundown of the skills and knowledge we needed to keep us safe, happy, and mostly dry. (2)

The most important thing is that they talked to us like the beginners that we were, and they didn’t expect us to know anything. “See that buoy out there?” the rental guide asked, pointing out over the water. “See how it’s got the number 12? The numbers increase going out to the right. Don’t go out past the red one, or it starts to get dangerous. The numbers decrease going out to the left. Don’t go past eight, or you risk getting stuck in the mud and having no fun at all. See that red roof right above us? That’s home. If you get lost or scared, you can always come back here to us.” I was surprised how comforting it was to hear that.

Essentially, they were saying, “You’re doing something new. It’s natural to get confused, disoriented, or scared. Here’s a safe place you can go if all else fails.” Having that escape hatch was critical, massively reducing any anxiety I was feeling.

They provided us with life vests, a watertight bag for our stuff, boards, and paddles; held our boards stable; and helped us get out on the water. (3)

Fun fact: water is really squishy. It’s not nearly as solid as dry land. When there’s no helpful guide holding your paddleboard steady, you realize that keeping everything stable becomes your job. As my board began wobbling like hundreds of crazed kamikaze fish were battering the underside, my first instinct was to stare at my feet and will them to stillness. This worked, kind of. (4)

I achieved a semblance of stability, but every muscle in my body was totally clenched, and I very quickly began cramping. This was not the relaxing, meditative nautical activity I was promised. On top of that, I realized that I had forgotten to paddle, and the light current was carrying me away. (5)

My beautiful saint of a wife called out to me, snapping me out of my spiraling. “Come on!” she yelled, waving, as she calmly scooted away from me like an elegant ocean princess. This was actually really helpful because it gave me a goal to focus on achieving rather than just focusing on how uncomfortable I was in this new unknown arena.

I tentatively dipped my paddle into the water, switching sides every so often. As I began to paddle and find a rhythm, the training that the folks at Rock Kayak had given us came back to me. I started to make progress against the tide, following my wife.

While I was focused on paddling, my board also settled into a rhythmic motion, rocking naturally with the surf and my motions. No more frantic wobbling! Throughout the day, I slowly realized that the concept was relatively universal: The more I focused on things that were far away, like the scenery and my overall goal, the more natural my movements became and the more efficient my paddling was.

The tides that turned my stationary targets into a moving goal were less of a problem for me. The second I focused on close-up issues—Am I doing this right? Here comes a big wave! Is Jenny going faster than me?—things got wobbly, clenchy, and unproductive. (6)

Shortly after I mastered the complex art of standing still and paddling, a new problem cropped up: My feet started cramping. My mind started to race again. What was I going to do? I was out in the middle of the water. It wasn’t like I could just step off onto dry land to rest my poor feet! It wasn’t like I could just kneel down right there on the board … oh.

As it turns out, it’s fairly easy to kneel or sit down from a standing position when on a paddleboard.

I may not have looked like the coolest hot-rodding paddleboarder out there. I maybe moved a little bit slower than Jenny. But I was able to still move forward while preserving my mental and “foot-al” health. And there is no shame in that. (7)

I transitioned from standing to kneeling and back again several more times that morning, and knowing I could do that offered me another escape hatch that drastically improved how much fun I was having.

Now that the immediate emergencies were dealt with, I began a really amazing, zen-like experience. I paddled around, enjoying the sun and the ocean, the smell of the salty spray, and the sounds of the harbor. I said hello to a couple of seals sunning themselves and some otters that were floating around. This was the relaxing, meditative activity I was promised. I would definitely be doing this again. It was then that I had my most important revelation.

Why was I so worried about falling in?

That was easily the worst thing that could happen to me. However, the water wasn’t that cold, my phone and wallet were tucked in a waterproof bag, I was wearing a life vest, and most importantly, I know how to swim. Oh yeah, that’s right. I’ve been swimming since I was in elementary school. (8)

In all of my panic and spiraling, I had forgotten all of the other skills and coping mechanisms that I’ve developed in other parts of my life. I had never been in any real danger—at least, no more than the danger of getting wet and a bit chilly. Maybe I’d smell like fish for a while. But I certainly wasn’t going to die!

On top of that, I realized there was no one out here that actively wanted me to fall in (maybe besides Jenny, and then only with love and the desire to laugh at me looking silly). In fact, were I to ever be in any real trouble, everyone out on that bay would immediately rush to my aid. I had been too busy looking at all of the things that could go wrong to consider the vast safety net that was available to me if I needed it.(9)

With that, we finished out the remainder of our time on the water, peacefully enjoying each other’s company and the gentle rolling of the sea: Jenny, deftly maneuvering in and out of the boats, and me, goofy but well-meaning, surviving and having the time of my life.

I highly recommend it to anyone who is interested (and within easy traveling distance of a good body of water), and I’d happily take anyone who wants to go, sharing my newfound wisdom, because I know that they will love it, too. I’ve got a lot to learn and a long way to go to be a great paddleboarder, but I do consider myself a paddleboarder, and I’m proud to be one.


1. There is a lot of tooling in the programming world. Complicated build processes, tricked-out editors, and—the config files! Oh, the config files! Especially for a beginner, it is intimidating to figure out what is needed. What are the right tools? What is the right way to do things? It’s easy to forget that the important thing is to just get started. The learning and the tooling will come when you need them.

2. Mentors can come in many different forms. Of course, there are the more traditional teachers, like high school and college professors and bootcamp leaders, but a person on a message board online or a co-worker with a little more experience can also be a great mentor. The important thing is that they help you to be productive and safe, and they push you to grow.

3. Mentors are critical to the path of learning how to program, and the best ones know that learning needs to be a challenging but 100 percent safe experience—at least at the beginning.

It’s the mentor’s job to make sure the mentee knows what they need to know to progress and be safe, as well as how to find help if they get confused. Without this “safety net,” a learner can easily get lost and confused, eventually giving up.

4. While learning spaces like college, apprenticeship, or a boot camp are relatively real-consequence-free that first time you are on your own, working on your own project, or working at a first job, the training wheels come off. Your actions can have real consequences, and your mistakes can affect hundreds or thousands of people. This is, understandably, terrifying.

5. There’s a lot to do as a new programmer: learning all there is to learn, working on your portfolio, publicizing your personal brand, and more. To make things even more difficult, the industry is rapidly evolving, making your learning a moving target. If you are standing still, then you are falling behind! This is, understandably, stressful.

6. Don’t focus so much on the things happening right now. Don’t worry about whether you’re progressing as fast as other people. Don’t worry if you are doing this or that little coding thing “the wrong way.” Focus on the goal. If your goal is to get a job at a big tech company, always keep that in your mind as you’re working. If your goal is to teach, make everything you do align with that goal.

A common mountain biking tip is to look at where you want to be. If you stare at the big rock, you are going to run into the big rock. The same applies in tech. This will help keep you from burning out, and it will help you ride out the little bumps and issues along the way.

7. It is OK if you need to take a break. Burnout is real, and it is powerful. No matter what, your physical and mental health should come before any deadline, boss’s mandate, or performance review. If anyone tells you otherwise, they don’t have your best interests at heart. Full stop.

8. When things get crazy, especially in an industry where you are always learning and finding out how much you don’t know, it’s important to remember that you do know some things. Remember what you’ve practiced, and do as much as you can to set yourself up for success and minimize the consequences associated with failure.

The goal is to plan ahead and leverage your knowledge so that when you ask yourself, “What’s the worst that could happen?” the answers aren’t that scary. Not sure if your code will break production? Write some tests. Have a co-worker look at it. Run it. Going to ask for a promotion? Do your research. Figure out what a reasonable salary increase is. Document all of the good things and extra work you’ve done. Remember the skills that you have.

9. This is complementary to #7. Build a support network. Find people who love you, will lift you up, and want you to succeed. Then, lean on them when things get hard. They’ll be there for you if you fail. Don’t forget that means you need to be there for them, too!



Like my stuff? Have questions or feedback for me? Want to mentor me or get my help with something? Get in touch! To stay updated, subscribe via RSS