Bootcamp Diaries - Week 3 - Fundamentals Part 2

Bootcamp Diaries - Week 3 - Fundamentals Part 2

2020, Aug 30    


I got up early and it was a nice day, so I travelled into town to work on campus. A couple of the other guys were also there today.

Looking at the schedule, I knew that today was going to be about recursion. Despite studying this topic on freeCodeCamp and watching countless Youtube videos on it, I found it quite a tricky topic to understand, so I hoped today would help. We had a lecture about recursion with diagrams of how recursive functions work with the call stack. Then we pair-programmed to work on some recursion-based challenges. I found these really difficult to understand and even if we came up with a solution, I still didn’t understand how it worked and what it was actually doing. It didn’t seem like that complicated of a concept, but my brain just didn’t want to compute.

At the end of the day, I felt a bit upset and stressed that I didn’t feel like I understood much today and I wondered if anyone else felt the same. I got home and had a little cry and wondered if I can really do this. But then people are always telling me that if coding was easy, everyone would be doing it. I think some things are just going to take perseverance, so I’ve started writing a list of topics to revise further.

PS - I found this video that has a great explanation of recursive functions for when I need a reminder.


I was really tired after stressing about recursion last night, so I worked from home today to get an extra hour of sleep.

Today we were beginning to look at Object Oriented Programming

The exercises we were working on today involved using Factory Functions to create objects with the same basic blueprint. We had a solo sprint for the afternoon that was based on the behaviour of stacks and queues. I know I’ve studied Factory Functions before but I was struggling with these today…maybe it was the stack and queue thing that was throwing me off. Again though, I had a moment where I felt like I was not good enough because I didn’t fully understand. The tutors did reassure us though that even if we only understood about 40% of a topic then that was ok, but I just hoped that things would click a bit more for me tomorrow.


I was looking forward to today because I saw that the sprint was Pokemon related and you could say I am somewhat of a Pokemon fan!

The work was all related to Object Oriented Programming again, but today we were looking at constructor functions and how to add methods using the prototype property. This already made much more sense to me than the Factory Functions we were doing yesterday, so I already felt more positive.

Before lunch, we got paired-up for our pair-programming sprint which was…to make a Pokemon battle game! Ok I was so hyped for this! We needed to use constuctor functions to make blueprints for Pokemon, trainer and battle objects. The idea was that we could create new Pokemon and trainers with them and then battle them against each other, using moves and deducting the correct amount of hp and so on. Ultimately, it would be playable and interactive using the computer terminal. My partner and I got to work with the challenges and I was really enjoying the process as I felt like I had a good understanding of how the constructor functions worked and it was fun to talk about Pokemon while we were writing the code!

By the end of the day, we’d accomplished the day’s challenges and tomorrow we will be working on the 2nd part of the game and hopefully get it completed so it can be played! I really enjoyed today and felt like this was just what I needed to pick me up after a difficult start to the week.


I had a dream about zombies last night…it might be from playing DnD recently…

Anyway, today we were introduced to the wonderful sprinkling of syntactic sugar that is JavaScript classes. I really like classes. Essentially, they are doing the same thing as the constructors and prototypes we were using yesterday, but they look much cleaner and I actually think they are easier to understand from first glance.

Our first task for today was to refactor our code from yesterday into classes; this was pretty straighforward. Then we worked on our game some more in order to get the Pokemon battles working. Again, by the end of the day we’d managed to pretty much complete all the tasks and we were feeling pretty proud of ourselves. I think we really figured out some great logic in order to calculate Pokemon attack multipliers and how to ensure things were calculated correctly. The only thing we didn’t manage was to get the game working on the terminal using the inquirer.js library, as we just ran out of time, but it’s always something we can do later.

We had a Zoom conference at the end of the day for people to discuss their code and show how their Pokemon game worked. It was really great seeing other people ideas and how they had achieved similar things as us but with completely different code!

I decided to carry on working past 5pm as I wanted to keep adding things to the game and work out how to get it working on the terminal. I thought the documentation for inquirer was pretty confusing, but I managed to figure out how to get it running…after working on my game some more, I realised that it was midnight and I needed to sleep! There are still plenty of things I want to add to make it more fun and add some complexity; so far you can only choose from one of 4 starter Pokemon and you can only battle Misty, but I plan to add more Pokemon and different gym leaders / rivals to battle. It will be a fun little side project to work now and eventually I can add it to my portfolio! I also love the idea of making more simple games like this.


I was pretty tired after all that Pokemon battling last night! Luckily today wasn’t particularly Zoom heavy, so my eye bags didn’t matter too much! Also last night I dreamed about a talking cow.

Today was a review day; we were given challenges to solve based on the meatiest topics we’ve covered so far including array methods, object-oriented programming, recursion and closure. We were to use test-driven development in order to solve these problems. Test driven development is the way we will continue to work throughout the course.

We all had a 1-2-1 Zoom call with our group tutor today as well, so we could discuss how we felt after this week and ask for help if we needed it. I found this particularly useful during my struggles with the closure challenges. I have plans in place to practice closure and recursion some more in my own time now though. Initially I was worried about feeling like I had enough support with all the tutors speaking to us remotely via Zoom, but so far I can say that the tutor support has been amazing and there is absolutely no need to worry.

I am feeling really exhausted after this week! It’s been a bit of an emotional rollercoaster really, but luckily it has ended on a high. This weekend is a bank holiday, so we’ve got three days off. I do plan to have some time for rest and self-care, but I am also going to spend a few hours practicing things from this week. I got a new game recently called Spiritfarer which has been a really nice relaxing game when I just want to chill, so I’ll probably play that for a bit too. Now, pass me the gin!

The Weekend

On Saturday I cut and dyed my hair whilst watching some more videos about recursion on Youtube. Oh and I also binge-watched season 3 of Aggretsuko on Netflix.

On Sunday (It’s Sunday evening as I’m writing this) I worked on my version of the Pokemon battle game some more and added a few extra improvements. I even wrote a recursive function which would call the battle turn and allow the player to choose whether to ‘attack’ or ‘run’. Woohoo!

pokemon battle game terminal image