Problem Solving

7 May 2022

In this blog, I am going to talk about several problem solving methods and some of my own experiences of problem solving in my learning journey so far.

Blocked on a simple problem

I was stuck literally at the very first java exercise in sprint 3. The exercise was easy, and most part was done, all I needed to do was to type return “Hello world”. I was 100% confident when writing the code, but the result said I did not pass. I checked what I wrote again and again. I even googled ‘how to return values in java'. I almost reached the point to think that do I need to restart the computer :D I thought I’ve tried whatever I can maybe I should ask on discord. When I was scrolling the unread messages on discord, a facilitator’s word caught my eyes. She said need to be aware JS is very case sensitive. I checked the code again, and finally found the problem, I typed “World” instead of “world”.

I think that was a good lesson that Java wanted to teach me at my very first day. From then, when there is a problem, I always check my spelling, notation, brackets before going any further.

Solved a problem elegantly

In problem solving in java, I am still at the stage of trying different things without knowing if it is going to work. When I was doing the find Scooby challenge, I got an error message saying result undefined. I then tried to console.log the result and I figured out that my code was running well, but I did not consider the situation when there was no result coming back what I wanted the computer to do. So I added some if statements. And it worked! I don’t know if it is an elegant solution to the problem, but it was very satisfying.

Problem-solving techniques

I am confident with:

Googling is always my first solution. I google to see if I am not writing the code right or if there are some other ways to solve the problem. I literally google every single problem I encountered. I started to read error messages and console.logging to solve problems when doing Kata challenges. Rubber ducky method is also one of my often used techniques. Instead of talking to a rubber duck, I talk to myself. This technique really helps when I need to organize my thoughts when the problem need several steps to solve.

I will need to work on:

I am trying to write pseudocode to break down the challenge to small steps. It is working, but I think I need to be more specific with each steps. In fact, I should have a clearer plan in my mind first. Asking is always a difficult part for me, probably because of my personality. I consider it is one of my limitations that I need to work on. I am starting to struggle more in this sprint. I can probably save lots of time if I reach out for help as soon as I need. I can also learn other different ways of problem solving by asking others.

With surprise:

To be honest, during the first two sprints I did not understand why we need to write reflections after each exercise. As the learning goes deeper, especially when we started to learn java, I realised I was totally WRONG about it! Writing reflections helps me to organise my thoughts and ‘forces’ me to rethink what I’ve learnt and what I’ve done. I can write the mistakes I’ve made in the reflections and try not to make it again. I can also write what I felt I’ve done it well to encourage myself.

back to Homepage