w2d3
What we did:
Test Driven Development. Ruby and rails uses a specific library, or framework called rspec which helps you test out new features as you go along on your project.Â
Imagine you’re hemming a jacket piece by piece. Each piece of the jacket needs to fit exactly to the person you’re hemming it for, therefore you need to have them to fit it each time you make a change or hem an additional sleeve. It’d be tedious to call the person each time to come over for a fitting each time right? TDD is like creating the jacket and the mannequin at the same time. The mannequin makes sure the the jacket fits, and the jacket is able to adjust to the mannequin if there are any additional pieces added.Â
After lecture was our project for the day, which is poker. While I’m not a poker player, I’ve recently become intrigued by the numbers, strategy of poker, I even watched several hours of videos on Youtube to see what the pros do! While setting up a game of poker with several players has gotten somewhat easier, the main meat of the project was figuring out the poker logic of which 5 card hand beats which 5 card hand.Â
I’ve ordered the algorithm by the best hands in terms of Royal flush, straight flush, four of a kind, etc... and assigned a numerical value for each type of hand, now it’s time to figure out how to get those tiebreakers.
Topics where I struggled:
algorithms. Seems like everyone else can whip up an ai quickly out of the air, while I need to picture all the pieces of it on pen and paper.Â
Felt a lot more improved:
Practice assessment taking. Maybe it’s because of all the hours spent working on classes and instance variables but I’m starting to understand how classes and methods access each other in Ruby.Â
Code that == Mind Blown!
instance_variable_set(arg) - Allows you to access private methods from a class even though they’re specifically set in private! Although not typically recommended,Â
How I’m feeling:
Maybe it’s because the midweek but I feel like I’m still able to code or practice for another 3 hours tonight. Will certainly crash this weekend.
6/10 motivation
Code Music
https://www.mixcloud.com/Mike_AD/late-night-alumni-the-122-130bpm-selection/
Sidenote:
I feel like I’ve been ignoring other aspects of my life as I basically devote a majority of my time to a/A. For example, I haven’t clipped my nails this week, or even had time to check the blogs I usually go to! Please read and update me:
www.millionmilesecrets.com
www.thepointsguy.com
Checkout my projects!
https://github.com/theRealYoshi
I’m taking suggestions!
https://yoshihiroluk.typeform.com/to/ilJBBy













