Eleventeen

20 Aug 2020

Several weeks ago, I’d gotten in the habit of at least starting my blog post first thing in the morning. I’m going to go back to this practice as it makes the end of the day a little bit more manageable.

So before I get things kicked off with code talk, i want to tell you about my new favorite kitchen appliance. A true necessity in life: The Instant Pot! OMG this thing is amazing!

So about 3 years ago now, maybe even more, my brother & sister-in-law got everyone in the family an IP for christmas. A really nice gift actually. They raved about this thing. For me, I certainly appreciated the gift, but I was also under the impression that it was just another fancy kitchen appliance that would take effort to learn how to use and that would, like all fancy kitchen appliances, get used maybe once every 6 months or so like a waffle iron or a fondue pot or one of the many other kitchen appliances that we own but never use. It was nice to have, but not a necessity in life.

Being home with the kids for a week and a half on my own was a nothing less than a blessing in disguise. First of all, I had a lot of fun with them. Maybe not in every minute of each day, but overall, I was very happy to be home with them and have yet another opportunity to spend that much time with them and watch them grow & learn before my eyes. In fact, this past Sunday was the first Sunday in months where I got the Sunday-blues–the blues that surface after a really good weekend before returning to real/normal life. Ironically, feeling blue made me happy, because it meant that I really did enjoy my time with them and that my confidence in taking care of them had grown.

Second, this time allowed me a little time to think about the needs of my family instead of spending all of it either solving work problems or exhausted from such. The truth is that I suck at planning & preparing dinner, and quite often we result to TacoBell or pizza or some other form of take-out. I am also a very good customer of Home Chef.

In this time spent thinking about the needs of my family, i got a craving for curry chicken. I had chicken & butter, and my pantry is always loaded with curry (it’s my second favorite spice shadowed only by clove). I found a recipe for butter chicken using the instant pot, and so i did. And it was not only delicious, but also yielded only like 2 dirty dishes. I was impressed…

So the next night, I decided to try chicken & dumplings. Huge success! I didn’t even need a recipe aside from the dumplings and time to cook. I was sold. I used that thing every night last week! And as someone who typically eats out probably 5 times a week, we ate out once last week!

I love cooking with it so much that on Sunday, I let Keith sleep in, even though it was probably my turn, just so that I could try breakfast in the thing. I made egg bites with bacon, cheese, & spinach. Leo, the baby (!!!), ate two whole ones, and even Rex, who is a picky eater these days, ate a whole one and asked for more even though he didn’t eat the second serving.

When Keith tried them, he became kinda wide-eyed at how much he liked them. So that evening, i made a double batch so that we could grab them on our way out the door in the mornings (we are getting sick of bagels!). He has complimented me everyday this week for making these and tells me how much he loves having them in the morning because they are so good, convenient, and easy to eat.

So, it might have taken me a few years to try the thing and get on board with the Instant Pot, but I am now a believer in the IP. I f*ing LOVE the thing, and i was wrong to judge it; it is a necessity in life. I may even cancel my HomeChef–I was disappointed when one showed up last night, because it meant I was going to have to cook those instead of IP meals.

On to the real stuff. Today was a good day. I watched a clean coder video on the SOLID principles. Then i wasted two hours trying to map out 50 or so triangle numbers & their factors in excel to see if there was a pattern. Finally, i went back to it and started all over. I saw one example online, but he did the same thing I’d done only in python. I’m not sure why his worked–maybe he let it run for hours.

I scrapped my previous work and started anew. I decided this time to not map all the triangle numbers out and certainly not the factors of each triangle number, and instead just roll through a factor-count loop adding to the triangle numbers along the way as needed. It was easy! And only like 2 functions of 4 lines each–not 7 functions of 12 lines each! It took 3.17 seconds to find the first triangle number with over 500 factors.

I don’t know why i struggled so much with this one yesterday. The take-away, i think, is to focus on the information that is actually required to solve the problem and nothing more. I didn’t need to map out every triangle number–hell, i didn’t even know how many i was going to need, and plus calculating the next triangle number was easy, so there was no reason to write a massive function to do them up front.

Once that one was done, i’d finished everything for the week, so i looked at euler 13, and solved that one in about 5 minutes–it seemed too easy to be real, and so i wanted to just put my initial thought to the test. It worked, so i committed that one too. Then i remembered i needed to practice bowling again.

That went smoother today, and i think my tests are set up well. When I compared today’s interaction to yesterdays, I’d realized that I’d made a number of improvements both along the way and after with refactoring, which was pretty cool. I sent it to my dad to ask him for review before i practice it repeatedly–i’d hate for it to be wrong and to study it wrong.

I also reached out yesterday to a local Agile group in BTR. Their meet up page said they were meeting tomorrow actually, but unfortunately, he replied that they are not meeting at this time. I responded with some more questions to see if he knows of any online meet-ups or support. We will see.


Rex:
Ask Rex to count: one, two, three, four, five, six, seven, eight, nine, ten, eleven, twelve, fourteen, eleventeen, twelve, fourteen, eleventeen, twelve, fourteen, eleventeen, twenty!

Leo:
Leo made me so mad this morning. I got everyone ready to go to school. As i was getting his lunch ready for school, i saw him go into the bathroom–i should have known… I finished his lunch, asked Rex to get his shoes on (“na-na-na-na-na, no shoes”, he says), and went to fetch Leo. When i got to Leo, he gave me a big smile (oh, he was a happy boy!) and I very quickly noticed that he was soaking wet and covered in green finger paint soap (he was also still red from the crayon he snacked on ten minutes earlier). I had no choice now but to throw him in the bathtub. So he got a quick 2 minute bath, then I got him dressed again, buckled Rex in, and then put his socks & shoes on him while he snacked on a pancake and counted to eleventeen.