Sunday, March 4, 2012

Learning computer coding

A report not about the actual computer code,
but on how I experience the learning process.

Multitasking on leap day 2012

Just one week ago, on Sunday, 26th February,  I enrolled to a free online course at
Well, not one like "Google"!! They are not going to teach us that. The main goal is to understand how coding works. The search engine part is only to get people interested in this course and is a basis for the exercises.

Now, I've been out of school for some years and thought it challenging to see if I still could learn something new this way. And if I would manage as well as in school or do much, much worse since I'm "out of practise".
"Class" already started a week earlier (on the 20th), but it was still open for enrolling and the first set of "homework" was not yet closed. So, anyone interested could still catch up and be "graded" as any other that had started "on time".

The first unit went in very small steps, with quizzes to test how well you understood the lesson. All in all there were 40 lessons for the first unit and week. 
When I saw that, my first reaction was "ooff" that's a lot to catch up with. But actually it wasn't. Each lesson has a short video between 30 seconds to maximum 8 minutes; most range on 3 minutes. It doesn't take much time to watch them. To understand what is being shown, well, that depends on how well you grasp the contents.
And on how well you concentrate and not distract yourself (or get distracted) if you forgot to "shut out" any outside influence i.e. phone, doorbell, demanding children and pets or even other websites you follow, like G+, at the same time.
I was lucky to have some time to myself in the next few days after I had enrolled. And the homework deadline had been pushed one day behind too. Thinking that it was all so easy, I hurried through the lessons, quizzes and the homework. I was finished fast. Too fast, I know now, as I didn't take the time to read the questions for the homework properly and got many of them "incorrect" because of that.

No, I'm not disappointed about that at all!!! It taught me something too!! :D
It's part of a learning process to realize that you need to read carefully and do exactly what is asked of you. And not creatively make a new question out of the one asked. Sure, the answer to the question as I had interpreted it was correct, but it was not the correct answer to the one asked.
That is a little problem with this online course. Different with school classes in the traditional way, here a computer examines the answers. For the computer program there is only a "true" or a "false" to the question. There is no "you did it the right way, but it is not what had been asked of you to do".

So, besides the actual understanding of how the coding works, I also learned that:
a) I need to take my time and not hurry, assuming I already know the answer
b) I need to concentrate on what I'm doing fully
c) I have to exactly follow the rules that are given
d) I have to think like a computer

And the last two points are the ones that feel not so good to me. I have my own mind, want to be "free". But for this course they are necessary. As to the first two points listed: yes, that is something good to learn. Not only for this course, but for every day. To be able to concentrate on what you are doing fully and do it with care.

Unit 2 started before the homework of Unit 1 was returned. And like most of the students (They have been commenting in the additional forum about it. I joined the forum a few days after I had enrolled when I noticed a question asking about how old the "students" were and the poster stating he was "old", over 40, which I think is not old at all to learn something new like this.) I, too, started with Unit 2 before I had the results of my homework. Eager to go on, confident that I had passed the first unit well, and as I wanted to do things with more care and not in a hurry, start early enough to be able to do that.
When the homework to Unit 1 was returned I was well into Unit 2 - and had to laugh out loud to some of the answers I had given. By now I understood what I had done wrong - even without having seen the answer video. Yes, I had finally understood the lessons in Unit 1! But too late for "good" homework grades. *lol* (Thinking of learning as a competition here.)

Still, although I gave myself more time for each lesson, I was "through" with them fast again. Time to start on the homework. This time we had to do some coding that advanced the one we had in the lessons. The question was similar, but added a "creative" note to it. It made it challenging to write it all yourself. Not just repeat what had been taught in the lesson.
I was so "into it" that even on my way to work or back home, or right before going to sleep and right after waking my mind jumped to the still unsolved homework question trying to figure it out. It was obsessed to get an answer. 
I do not like this "obsession" (you could call it even addiction) and it made me think on why and what for I do this course. Work, rest, fun and other daily activities have a priority (not necessarily in this order ;) ) to solving these homework problems. I do not have to solve them! Nothing will happen if I don't; except my own "ego" might feel "cracked" or disappointed. So, I took a "time out" to do other things: painting, being on my favorite websites, spending time away from the computer again and again.
Sure, when returning to the coding my mind had to think hard and "change the way of thinking" again to get into the coding. But oddly enough, with giving myself more breaks between working on the homework, there were moments when "suddenly" the code I wrote finally worked (that is: gave a correct answer and not a red text telling me there is a mistake in the coding or produced an answer that was not the one I had wanted to achieve).
Whenever that happened I felt "free"! My mind was "done" with the problem and I felt no more "urge" to go on. 
Now, there is only one more homework to do. It's marked with two gold stars. This means that it's not expected that everyone will solve them already and will require much thinking. 
Well, even "normal" questions took me more time than I felt comfortable with. I still have some time until the deadline for this one. Maybe I will spend some more time on solving it. Maybe I have sudden insight at how to do it - and when testing it, it actually does give the "correct" answer. But is not "necessary" for me to solve this last question. I will get the answer (or at least a useful hint at how it can be coded) when the homework gets graded. I can learn then how to solve similar problems and not "waste" so much time on trying to solve it all by myself NOW.

I feel, I already learned a lot. Enough that I could stop with this course now. 
Not enough about the code and how to use it, not for building a search engine easily. For this I will (have to) continue with the course. It does interest me, or I wouldn't have started with it in the first place. 
But I learned enough to know that code writing is not my interest as such. Nor is the way a computer thinks my way. Nothing against structure, clear structure too. But not as rigid. Not so "close-minded". There is no way for me to express what I think, feel and want to share this way.

You just need to look at how I composed this text. There is structure; but I also break free from it when I feel it is necessary. Necessary for further explanation or additional thoughts that do not actually fit into the stream of the happenings described.

As a conclusion (after a week - this is not a "final" conclusion - such will never happen as my whole life consists of continuous learning, even about myself) I can say:
I do not regret having taken this opportunity. 
Even if it took (and might still take) a lot of my "free" time that I could spend on other things I love to do. And even if I won't succeed in this course and be able to actually code a "program" all on my own. I do understand it a lot more than before. 
And I understand ("get") other things much better and easier than before too. Things that seemed strange to me suddenly make sense. In a way that I can not yet put into words. Seeing i.e. movies, I had liked a lot, again and now seeing even more "contents" and messages (hidden behind the actual scenes and action) in them. What a wonderful expansion. :D
And I "re-found" what is more my "inborn" ability (or abilities :P). And that I prefer the non-usual way of doing things over the strictly regulated. 

Once the course is over in about another five weeks I might give an update on this - if there is anything that needs to be added.

PS: Writing this took about as much as solving one of the last homework questions. But it was more fun to do, gave me less "headache" and can be shared so much better than that little code I wrote.


  1. Awesome! You’ve said it all beautifully. I love this post.
    Keep it up...

  2. This is a good post, but I disagree with a few of the conclusions you reached.

    Basically with #3 & #4 of the list of things you learnt after the result of hw1 was out.

    With regards to the homework - there are certain things that you have to keep in mind, because the code is being graded by a machine, which is just an algorithm which basically just matches an input with the correct output. So if you used print instead of return or used true or "True" instead of True, your answer will come out wrong, even if the rest of it, and your logic was correct. And TBH, it's not nailed on that a human checker would give you credit for such mistakes, I know I wouldn't.

    Now about having your creativity restricted and you having to think like a machine - You couldn't be more wrong about that.

    You don't have to think like a machine, you have to think like a programmer. And to be a good programmer, you should know a little about what the compiler/interpreter does with your code, but that is not the same as thinking like a machine. And to be honest, the computer doesn't really think, at least not the ones we have access to. You have certain restrictions, or constraints, when using programming languages which are more strict than any human language, but that is a necessity - disambiguity is a requirement. But that doesn't necessarily mean you have to kill off your creativity. There are multiple ways of coding something, and coming up with a good way which suits your requirements can be a creative process. I came here from my "Recommended Readings" thread, and there is a link there to Programming is an art -
    Hopefully with time you'll realize that you don't have to think like a machine to code, rather you have to be(should be) creative about how you can bend the machine to you will

    1. As I already also commmented back in your thread:
      This was the first post about learning computer code.
      Time has passed, experiences were had and opinions changed.
      I agree that there is "creativity" possible in coding.
      At the time of this post though I hadn't experienced that yet.

      But I must also add that it still is not my way of being creative.

      Thanks for sharing your thoughts on this.