Please visit my new campsite listing site ukcampingmap.co.uk


Posts Tagged ‘self-taught’

How I’d teach myself programming, if I could do it all over again

Wednesday, February 17th, 2010

As I mentioned the other day, web development as a career is rare in that you can just pick it up off the internet unlike, say, luxury pet grooming. But it took me a while to find good strategies to learn what I wanted to learn. If I had a time machine I’d go back and tell myself the following*.

Don’t buy beginners guide programming books

I bought a couple of these on php/mysql and javascript. I won’t say they were a complete waste of money as I did learn the basics from them, but there are several good reasons not to rely on them for your starting point:

  1. These books are almost always a long-winded, incomplete version of the programming language’s documentation (which is normally available for free online) structured around building an example application which probably bears little resemblance to something you would like to build, e.g a quiz about the Simpsons
  2. Unlike online resources these books are not searchable with lots of easy to follow cross-references
  3. Online tutorials are more up to date

Find a good online tutorial

For any programming language there will be loads of beginner’s tutorials online; just search Google for “[language name] beginner’s tutorial”. the top results won’t however generally be the best, so open up lots of tutorials in lots of tabs, narrow it down to a few of the best and then bookmark them, before starting to follow one of them. If you get stuck on a section you can always try the explanatiosn given in your other bookmarked tutorials or search google for “[programming language] [topic] explained”. Below are some of my favourite tutorials:

Learn to use documentation

It took me a long time to realise that most programming language documentation follows  the same structure, and once you understand this you are able to teach yourself any language. Roughly, a programming language (at least, the ones I know) is a collection of types of thing (objects, strings, arrays, numbers etc…) and processes (loops, conditionals, functions) for manipulating things, and some things have built in sub-things (properties) and their own dedicated processes (methods), and most processes will only work on certain types of thing (arguments of the correct type).

Well written documentation will list all the above information systematically (together with the basic syntax and rules of the language), so that if you create a variable of a certain type you can find out what you are able to do to it, or if you want to use a function you can find out what conditions its arguments need to meet. An understanding of object oriented programming also goes a long way to being able to grasp documentation, but isn’t essential for a beginner.

Use libraries… lots of libraries

Not the ones with books. A library (sometimes called a framework) is a collection of software written by somebody else that takes care of some tedious/difficult processes for you. The classic example at the moment would have to be jQuery. Without jQuery the differences between browsers’ implementations of javascript would make developing javascript web applications a specialised and difficult task with unreliable results. Because jQuery is a collection of code that thinks about all the cross-browser differences for you (as well as doing lots of other useful tasks) creating reliable javascript applications is now something even beginners can take on. Some libraries also have thriving communities that build plug-ins to extend the functionality further.

And to make use of all this all you have to do is include a file (or collection of files) and get to grips with the library’s documentation (often called an API – Application Programming Interface) which, no matter how daunting it may seem at first, is guaranteed to be easier than writing all the code yourself.

Invest in some expert/advanced books

Beginner’s guides may have been made redundant by the internet, but there is still room for more advanced books. Yes, the information is probably on the internet somewhere but structured tutorials aimed at more advanced users are far less common than beginner’s tutorials. I won’t recommend any books myself as I don’t consider myself enough of an expert to judge, and I also don’t own many yet, but the ones I do have are full of techniques I couldn’t have worked out for myself.

And that’s how I should have done it!

*Like hell I would. Straight to the bookies it’d be.

Your friendly office idiot

Tuesday, February 9th, 2010

A friend of mine (whom I’ll be doing a website for shortly) mentioned last night that  she was impressed that I was able to learn all I know about web development from the internet (more or less)… and, come to think of it, so am I. There can’t be many careers where the internet enables you to become fully trained and, arguably, more informed than people who learn their craft just from courses and books.

But it got me thinking about how gradual a process it’s been, picking up all these skills. Starting with html, then on to CSS, then a little functional php and javascript, a slight detour into google maps, then on to fully OOP programming using jQuery and Zend framework. And I came to realise that for many of these, especially the early ones, the reason I’d started to look into them was because I worked with an idiot that didn’t understand what they were doing.

Indeed, there’s nothing like incompetence in somebody who should know what they’re doing to spur you on to learn how to do it yourself. If you’re dealing with an expert there’s very little chance your embryonic efforts will outshine theirs, and you’ll probably have little reason to want to bypass them anyway. But if you’re stuck with an idiot that constantly frustrates you with their incompetence and inability to do the simplest things, then it’s easy to convince yourself that you could do better, so you start to learn the basics, pretty confident in the knowledge that if you master these you’ll already be light years ahead of your resident idiot. Maybe all companies should have an official idiot hiring quota as part of their professional development strategy.

So here’s to you, idiots, for leading me, and probably many others, to a decent career.