I’m currently working on a JavaScript function to duplicate values from an array and return a new array. Tommy provided me with some useful advice, so I hope to gain a better understanding of this. After some research, I discovered that JavaScript has a `Set()` method designed specifically to remove duplicate values from an array….
Coding day
I shouldn’t have a book on my desk during the day when I should be focused on coding, as I often find myself distracted by reading. To avoid this temptation, I’ve decided to keep my book in the bedroom. I’m nearly finished with “Race Across Alaska.” Recently, I attempted to place a book on hold…
JavaScript and Belfast
Today I learned a few new things in coding. First, how to find the second largest number in an array: function secondLargest(arr) { if (arr.length < 2) return null; let largest = -Infinity, second = -Infinity; for (let num of arr) { if (num > largest) { …
A quiet Monday
Happy Monday! This morning, I’m feeling a bit uncertain about what to write. I’ve already had breakfast, taken a shower, and organized the pill boxes for both Tommy and myself. Last weekend was quite laid-back; Tommy wasn’t feeling his best due to his ear infection, so we opted to stay home and enjoy some time…
A rainy Friday
Happy Friday! Merlin is with Tommy at work today. I often feel stressed when Tommy takes Merlin along, as Merlin can be quite high maintenance, making it challenging for Tommy to focus on his tasks. It appears that Merlin is having a rough day; he’s been standoffish and aggressive. Tommy has called Kel to come…
New hearing aids
I have an appointment later today, so I thought I’d take a moment to write early. Today, I’ll be tackling more JavaScript problems, including figuring out the prime number function. Interestingly, I approached my routine in reverse today. Typically, I complete my morning routine, shower, and take my medications before having breakfast; however, today I…
Happy Middle of the Week
Yesterday turned out to be quite a lengthy day for us. Kel and I left the house shortly after 10 a.m. and arrived a little early for my first appointment, a mammogram. This was fortunate, as I needed to complete some paperwork before the procedure. The mammogram itself wasn’t too uncomfortable, though I always feel…
Hello Monday
I’m enjoying these JavaScript exercises; they are enhancing my understanding of the language. However, I often find myself Googling explanations for why certain things are written the way they are in JavaScript. I’m not sure if that makes sense, but I generally prefer to understand the reasoning behind a function’s behavior. When I seek help…
Happy Friday!
I didn’t get home until 6 PM last night, so I didn’t manage to write. I had my hearing test yesterday, and I wasn’t surprised by the results—I already anticipated that it wouldn’t go well. Kel and I left the house at 11 AM and headed over to her dad’s place. Unfortunately, he wasn’t feeling…
London calling
Tommy stayed home sick today, so I spent the day coding and taking care of him. He’s currently asleep. The weather outside is quite nice—unseasonably warm. I’ve been reflecting on the cruise we have planned for July/August, during which we will be in London for a few days. I did some research on London’s history,…