What I Wished I Knew Before I Jumped Into iOS – Part I

Written By Basel Farag

Earlier this year, Nikhant Vohra of Paypal told of the things he wished he knew before he dove into iOS development. In his article, Vohra focuses on what development tools and blogs he wished he knew of before he began iOS Development. My hope is to give you what I feel is the other half of the equation: what I wish I knew at a higher level before starting iOS Development and learning coding. It’s not just about the tools you use. For some, it’s also about mental preparation. I was certainly one of those individuals.

Focus on the Fundamentals

Focused man on eye test letters on white backgroundThis is a point that Nikhant hits upon, but I felt it was so vital that I wanted to discuss this subject once again.

Focus on the fundamentals.

No, really. Focus on the fundamentals.

When I was first learning Objective-C, I tried doing too many things at once. Rather than learning the language through solving puzzles or toy problems, I dove right into building an application.

Many programmers applaud this “trial by fire” approach. But I find it particularly flawed.

Imagine the following: you’re learning Japanese. While learning Japanese—before truly grasping the basics of the language—you try to speak to a group of Japanese tourists using the knowledge you’ve gained thus far. But the tourists don’t understand you. You place words in the wrong place, and use participles that typically mark the end of the sentence at the beginning of your sentences.

One of the tourists (read: compiler) may be kind enough to warn you or tell you what’s wrong—and if you’re real lucky—why it’s wrong. But being a tourist, they can only help you so much. After all, they did not decide to visit the country to help you with perfecting your fledgling Japanese.

Now compare this to the compiler in Xcode. The compiler may tell you what’s wrong or how your code is wrong, but it won’t always tell you. Therefore,  you will keep making the same mistake until you understand whywhat you did was wrong.

So how does one correct this?

Practice, practice, practice. Use the programming language you’re learning to solve as many toy problems as you can. Twist the language. Test code in simple applications if you’re using Objective-C, or in playgrounds if using Swift.

Visit sites like www.coderbyte.com and solve the simple problems there using your preferred language. Or pick up a book filled with traditional programming language problems for beginners and solve them using Swift.

If you invest the time and truly explore the ins and outs of the language, then I guarantee you that you will see your development skills soar.

Feeling exhausted. Frustrated young man touching his head while standing against grey backgroundMemorization Is Not a Dirty Word

Memorization tends to get a bad rep here in the West. People equivocate the emphasis on memorization with having poor creativity, especially considering that our neighbors in the East perfect learning by memorization in their pre-collegiate years. This may be true, but if so, it’s only to a certain degree. How can one properly and fluently use a language if they keep forgetting key components?

I’m not suggesting to memorize the entirety of UIKit and/or Foundation. Libraries are not meant for that. Rather, I’m arguing for deep understanding of a programming language to the point where one might be able to speak it fluently in day-to-day conversation. Sound strange? I thought so, too, until one of my mentors (the kind of guy who builds supercomputers as a hobby) told me, “Look around you. Code is everywhere. If you pick up a water bottle, that can be translated into code.” Weird? Yes. But poignant and true? Absolutely.

So how might one go about becoming fluent in their respective programming language? In my case, it was through the use of good, old fashioned flash cards…but with a twist. Use Anki card instead of paper index cards. Anki is a special program that only focuses on those cards your brain has trouble remembering. If Anki detects that you understand a specific card sufficiently then it will bury that card and instead focus on showing cards with concepts you’re struggling with. Derek Sivers has an excellent article on his process using Anki when learning Ruby. I highly recommend consulting it: http://sivers.org/srs.

Use Third-Party Open Source Libraries…But with a Caveat

Check every line of code of any library you import. I didn’t learn this piece of advice until I spoke with well known iOS Developer and MartianCraft CEO Kyle Richter. When chatting with him, he told me of many horror stories from the App Store of yesterday where entire swaths of the App Store’s products were useless because of faulty libraries.

Haters Gonna Hate

Thumbs downPeople will be mean, and people will doubt you, especially when you’re just starting out.

In truth, the development community has a problem. We are tolerant of bullies and those with superiority complexes. These people will be disrespectful, tell you to give up, and inform you that you do not have what it takes. And if you are a person of color and/or female, they will—depending on the community—judge you even harsher than they would the average white male. I remember a hackathon where people avoided working with me until they realized that I knew what I was doing.

Ignore these people. More often than not, they are either poor programmers themselves (although they fancy themselves as masters of the craft) or likely suffer from deep-rooted insecurities that have nothing to do with you.

Proceed as you want. You are the captain of your fate and only you know what your true limits are. Do not let others determine what those limits are for you.

That’s all for Part I! Look for Part II soon.