10 Day Check-In

An Update

Well I've made it 10 Days into #100DaysOfCode. I took a few breaks over the Thanksgiving holidays because food and family are great 😊
Hope all my fellow Americans had a great time and plenty of pie.

I'll probably take a day or two off per week going forward. After talking to a fellow Odinite about the challenge, I've come to the conclusion that streaks are a bit overrated. Especially since I'm currently able to dedicate 6+ hours per weekday to coding right now. Keeping up full consistency would feel more important if I was just able to do 1 hour a day.

So what have I been up to over these 10 Days?

Mastermind

I'm proud to say that I completed my Mastermind game! It's a command line version of the classic Mastermind board game built using Ruby. Here's the repo and here's a replit to quickly try it out.

In order to simplify the command line display, my game uses four digits between 1 and 6 for the code rather than using colors. The README in my repository should clear up any differences between my game and the board game.

This was a super challenging project for me, probably the most challenging thing I've made so far. I do feel some of my Object Oriented design is weak, but I knew that a lot of refactoring would be required to clean up the messiest parts (the method in GameLoop that runs a loop where the computer is guessing the code -- yeeeesh). I just decided to move on and take the OOD lessons I've learned into my future work.

I did learn a ton through making this. This was my first Ruby project that incorporated a standard Ruby folder structure, module mixins, class inheritance, keyword arguments, a few new-to-me array methods (notably #repeated_permutations), and probably more that I'm forgetting. Getting the computer to "intelligently" guess at the user's code was also a fun (and difficult) puzzle.

Practical Object Oriented Design (or POODR)

Another thing I've gotten into is the book Practical Object Oriented Design by Sandi Metz. This is a commonly recommended text for Rubyists looking to deepen their understanding of OOP, and although I've just only just started the 4th chapter, it has been a real eyeopener. The main things I've taken from it so far have been techniques for maintaining single responsibility and managing dependencies. The next section of the book is on Interfaces, which I know to be an important OOP concept, and I'm excited to apply its teachings to my Hangman project.

Serialization & Hangman

Next up for me in my studies at The Odin Project are serialization and a new project: A Hangman game. I've gotten through all the content introduction the concept of serialization, which was exciting because I can tell how powerful and useful it is. Today I began work on my command line Hangman game, and hopefully with the next update, I'll have something to show off.

Future Updates

I think I want to increase my intended update frequency to every 5 days going into the future, and I'm also going to start keeping a small journal to write in at the end of each days that I can refer back to when it comes time to write these blog posts.

Be back in a few days! Happy coding

30