Week 5

Workshops

This week’s workshops were mainly independent which meant I could work on my audio player. I managed to implement two new buttons as well as removing my arrays in place of objects. I really liked this new method as opposed to the arrays, as it felt cleaner and laid the code out in a more organised way. I was also able to add the drag and drop feature to my audio player which we learnt in a previous workshop. After I had finished my audio player I did a little bit of research into audio players and other ways they can be implemented.

In our technical workshop this week we learnt more about how we can write out functions and use loops in our work. We learnt about several different ways to implement functions and loops to produce different outcomes based on what we need. After learning these different methods of doing so, we were challenged to code a challenge called FizzBuzz. FizzBuzz needs you to print integers one-to-N, but print “Fizz” if an integer is divisible by three, “Buzz” if an integer is divisible by five, and “FizzBuzz” if an integer is divisible by both three and five. I managed to code a solution that used a for loop and an if loop.  

Lecture

In the lecture this week we learnt about the importance of compilers, interpreters, static, and dynamic languages. We learnt about these key ideas using ducks.  

The first thing we learnt about was compilers vs interpreters. To introduce us to the idea of interpreting line by line or compiling the whole of the code to run, we had to place ducks in a room and direct our partner over to the duck with instructions. We first did it where we could tell them as they went and adjusted instructions as it was happening. This was easy to do and led to the person always getting the duck. We then repeated the exercise but had to write all the instructions down first and if the instruction did not work, we had to reset and rewrite. This shows us how compilers and interpreters work when we change parts of code when we are debugging.  

After this activity we were introduced to static vs dynamic typing. This was something I was already familiar with but found this definition very easy to understand. We then learnt a bit about multithreading and how we have seen it in our own work. We finished off by learning about several coding acronyms that can aid us in our work. We learnt about DRY, KISS, Refactor, and YAGNI and their importance in our work.  

We were then given our ducks to keep as they can help us with getting a fresh perspective, helping us think, slowing our thinking down, and they will not judge us. 

Leave a Reply

Your email address will not be published. Required fields are marked *