Teach Yourself Programming in Ten Years

Intro to Programming Logic COMP-1029

Red River College

In Ten Minutes?

Tenminutes

Computer technology is ever changing. We must become life-long learners to keep up.

Are we doomed to become Jack of all Trades, and Master of None?

Search Google-Books for “Teach Yourself ? in ?” and we get over 1000 titles.

Samuel Johnson (1709-1784), a British author who created an important early dictionary of the English language, had this to say:

“Excellence in any department can be attained only by the labor of a lifetime; it is not to be purchased at a lesser price.”

Or Ten Thousand Hours

10khlogo

How to become an expert in your field (from Malcolm Gladwell’s book Outliers):

  • Where you’re born and when you’re born have an enormous amount to do with whether or not you’re successful.
  • Becoming a superstar takes about 10,000 hours of hard work.
  • Both of the bullet points above are far more important than the magical talent myth.

10,000 hours isn’t a magic number, it’s just a large one. Most people give up along the way.

“Ars longa, vita brevis, occasio praeceps, experimentum periculosum, iudicium difficile” – “Life is short, the craft long, opportunity fleeting, experiment treacherous, judgment difficult.” – Hippocrates (c. 400BC)

Always be Learning

Question

There is a lot to learn. Consider the Programmer Competency Matrix.

  • Learn to Question. Question to Learn.

  • Know you learning style.

  • Learning is bi-directional. (You are not passive knowledge sponges.)

  • Instructors are inspired by passionate students. (And vis-versa!)

  • Fixed Mindset vs Growth Mindset

Read

Reader
  • Read source code.

  • Read lots of it.

  • Find programming heroes (and read their code).

  • Find interesting programming projects (and read the code).

  • Read Blogs Using RSS. Examples:

  • Podcasts are great too (although not “reading”): * This Developer’s Life

  • Following Interesting Topics on Pinboard.in. For example:

Resources

Write

Typing
  • We learn by doing. So code.
  • Program as a hobby. (This coding should be fun.)
  • Contribute to an open-source project. (You can start with testing and documentation first.)
  • Re-write interesting projects in different languages.
  • Ask for feedback from peers and mentors.

Share

Share
  • Share your code with others.
  • Upload your favourite Scratch program to their website.
  • Share your Processing Sketches on OpenProcessing.
  • If you create a popular useful application, consider making it open-source.
  • Ask and contribute answers on Stack Overflow.

Praxis Makes Perfect

Ollie_monster_by_olivier_bareau

Praxis is the process by which a theory, lesson, or skill is enacted, practiced, embodied and realized.

The best people in any field are those who devote the most hours to what the researchers call “deliberate practice”. It’s activity that’s explicitly intended to improve performance, that reaches for objectives just beyond one’s level of competence, provides feedback on results and involves high levels of repetition [and reflection]. –Geoffrey Colvin

(I added the reflection part.)

Resources

Coding Kata

Kamae_no_kata

Kata (literally: form) is a Japanese word describing a way of doing something or a pattern of behaviour that is practiced to various levels of mastery.

A Code Kata is an exercise in programming which helps hone your skills through practice and repetition.

Overlearning the basics allows you to excel at the more difficult tasks.

Document Your Finding

Notebooks

You can’t remember everything so why not write it down?

  • Pen(cil) and Paper
  • Digital: OneNote, Google Docs, TiddlyWiki
  • Online: EverNote, Hosted Blog or Wiki

Resources

Source: Five Best Note-Taking Tools

Work Hard at Being Lazy

Chickenplayhard
  • Master a tool-set.
  • Build your own tools to avoid repetitive tasks.
  • Know your OS and IDE hotkeys.

Simple HotKeys

  • Copy: Ctrl-C
  • Cut: Ctrl-X
  • Paste: Ctrl-V
  • Processing Save then Run: Ctrl-S then Ctrl-R

Advanced Hotkeys

Test First if Possible

Build-website-checklist

You should know how to test your code before you write it.

Consider the questions in section one of assignment five on Boolean decisions.

For each question:

  • How many possible outcomes are there?

  • Can you develop a truth-table that shows all required tests?

Become an Expert Debugger

Computer_bug

There are three types of bugs…

Compilation Errors, also known as compiler errors, are errors that prevent your program from running. Most compiler errors are caused by mistakes that you make when typing code.

Run-Time Errors are errors that occur while your program runs. These typically occur when your program attempts an operation that is impossible to carry out.

Logic Errors are errors that prevent your program from doing what you intended it to do. Your code may compile and run without error, but the result of an operation may produce a result that you did not expect.

…and they are all your fault. ;)

Not All Solutions Are Created Equal

Horseshoes and Hand Grenades

Horseshoes_grenades_small

Close enough doesn’t cut it when programming.

Attention to detail is the most important quality of a expert programmer.

if (worldWarThreeAuthorized = true) {
    launchNukes();
} else {
    peaceAndLove();
}

Oh oh!

Type Quickly and Accurately

Typing-software2
  1. Test Your Typing Speed
  2. Practice Typing

Minimum Goal: 40 words per minute with 95%+ accuracy.
Strive For: 70+ words per minute.

"Steal" with Attribution

Steal

I stole the title of this lecture (and some of its content) from Peter Norvig.

  • Don’t reinvent the wheel.
  • Remix liberally.
  • List your sources.

Just don’t do this for your homework, unless your instructor gives you permission. You have to grok coding before you can intelligently evaluate any “borrowed” code. Plus, coding “by Google” (i.e. Copypasta) can add unneeded complexity to your code.

Defend Your Ideas

Cat_pushing_watermelon_argument_invalid

Learn how to make persuasive arguments about technical issues.

  • Support your claims with evidence.
  • The written word is powerful (if your write well).
  • Know your audience.
  • Be concise.

If you are unable to make a good argument when defending a decision then you may want to rethink your decision.

Sleep & Exercise

C457ea2d8100ee37653553dd19456c54

Move your body and get enough sleep.

Seriously.

Stretch your back and wrists.

Gives your eyes a break from the screen.

Even short walks and naps can do wonders.

To Do List

Resources

Taste vs. Skill

Explore!

Explorer
  • Always be Looking
  • Consider everything alive and animate
  • Everything is interesting (look closer)
  • Alter your course often
  • Observe for long durations (and short ones)
  • Notice the stories going on around you
  • Notice patterns, make connections
  • Document you findings in a variety of ways
  • Incorporate Indeterminacy
  • Create a personal dialogue with your environment
  • Trace things back to their origins
  • Use all of the senses in your investigation

I found this list blowing in the breeze in a downtown back-alley.

Resources

Source: How to be an Explorer of the World (Found after much Googling.)