A desk with computer and coffee cup.

Katie's learning blog

Problem Solving

31 January 2023

6 steps to structured problem solving
source : https://www.smstoolkit.nz/structured-problem-solving.

A time I was stuck...

This was when I was trying to figure out how to add all the new test scores to each student in the gradebook. I took a minute and reread the task again a few times and jotted down what I thought I would need to do to solve the problem. To make it easier I thought how would I write the code if I wanted to add the testscore to just one of the students. This helped me get into the process of how the code may look. Then I knew I need to use a loop but wasn't sure how to use a loop within an array. This is when I turned to Google and found the .forEach method. Then it was a simple step of adapting my code into the .forEach method and testing to see if it worked. There was a lot of trial and error and reading the error messages.

Througout the process I would find myself getting frustrated that I didn't know better or for making silly mistakes but after taking a break and talking to my husband he reminded me that it is all part of the learning process and even seasoned developers still make silly mistakes.

What did I learn...

I learnt to be easier on myself. That it isn't failing using the tools around you to help. That to be mindful of productive struggle but also knowing when to seek help.

Elegantly solved a problem ...

Creating my superBuzzFizz function. I felt so confident with what I needed to do, the only bit I was unsure was the exact syntax I needed to use to call upon a function within a function. I broke my code down into steps and fully understood how each part worked but then when I hit test it came back fail! I was so annoyed as I was so sure my code was on the right path. I looked at the error message it was showing and still wasn't sure. I put my code into chatGPT and they said it was all correct and should work, so my frustration was rising! I finaly thought something had stuck and I was improving then to keep getting fail really hit hard. So I went for a walk and did some mindful breathing. Then came back and looked at the test file, that is when it hit me I had put my code into the same file as fizzBuzz when it needed to be in the superFizzBuzz one I felt so stupid! I copied over my code and hit run and boom it worked! My eagerness to keep going with my learning meant I missed the part about completing it in the other file.

Techniques

Pseudocode:

Becoming more confident- I use to write myself notes in a notepad so now just using pseudocode instead. Definitely helps me break down my thinking.

Trying something:

Semi-confident, I feel this is just how I approach most problems by just giving somthing a go and then processing why it did or didn't work. Trying not to worry if I'll break something by trying though!

Rubber Ducky method:

Very confident, I am constantly talking out loud about what I am doing and most times I head to others to get help and whilst I am thinkning of how I will relay my problem to them I come up with a solution.

Read Error Messages:

Not really, still trying to understand what they are telling me and what that means. I am working on it and have researched different type of error messages.

Console.logging:

Semi-confident, I have only really used it when instructed too and couldn't figure out how I used it on my own code locally. Then after some Googling it all clicked. I used it for a few of my functions on the kata project. Will Definitely start using it more now I understand how to!

Googling:

Confindent! Google is my lifeline when all else fails!

Asking peers for help:

Semi-confident- It takes me a while to feel comfortable and safe with my peers to ask and not really knowning everyone properly yet makes me nervous.

Asking coaches for help:

Semi-confident- I have yet to get to the point where I have needed to as I have managed to find the answer either through google or trial and error. I think once we start getting more into projects and in person I will definitely be more confident.

Improving your process with reflection:

Semi-confident- When I have my 'a ha' moment I should reflect more on how I got there and what I did to be successful, but also taking a moment and reflecting when something isn't going right and what do I need for my own mental health in that moment.

I was reluctant to ask for help...

I always struggle with this as I want to be able to figure things out on my own, I know I learn best by making mistakes and then fixing them, having something to connect my research too helps me to solidify my learning. However like I previously said knowing how long is long enough to try and figure something out before I ask for help is a struggle. But more importantly knowing that asking for help doesn't mean I failed.