This was after completing their last problem: JavaScript Algorithms and Data Structures Projects: Cash Register.
Mom, it was a harrowing ordeal to get this thing! |
As you know, I track my time coding or learning to code with Toggl. How much time did I spend on this the last problem? In total about 9 hours and 52 minutes.
Holy mother... why?
The long and short of it is that you need to know the value of each of the currency item in order to solve the problem. I had set my penny to $0.1 instead of $0.01.
I basically solved this damn thing like 3 different ways after working with that incorrect original reference data the whole time, but could not get why the heck it was not solving. Part of the reason was because I was adamant on getting it done on July 12th so I kept cranking at the problem up until around 3am in the evening until I finally gave up for the day due to sheer exhaustion.
So roughly 9.5 hours was spent banging my head on this thing. In the end, I asked my husband for help and after a series of questions of why... that we identified that my penny was off by a decimal in like 10 mins. FML
And after that, the problem was solved as a whole pretty quickly after writing out the last bit of logic for the insufficient funds cases.
I should have given it a rest and/or asked for help much sooner. The bulk of the solution was written out and validated in about 2-3 hours and it would have been solved by then if it wasn't for being off by the decimal. I kept hammering at why it was not working with a tired brain which worked against me. And my stubbornness (which is amplified with the tired territory) pretty much made me avoid asking for help until I became desperate. I really need to stop doing that and be better about knowing when to stop and knowing when to ask for help!
So the takeaway from working through all these algorithms is not the content itself (though I did learn lots!) but mostly about myself in how to be a better person and a better programmer.
Now that this is done and over with, I still want to solve the remainder of the Intermediate Algos that I skipped, but I want take a break from algos problems in general for a few days so I can move on to the Front End Libraries section in FCC, the more fun and creative bits.
I am pretty pleased that I manged to get the second certificate before my 100 days on Tuesday!
Now that this is done and over with, I still want to solve the remainder of the Intermediate Algos that I skipped, but I want take a break from algos problems in general for a few days so I can move on to the Front End Libraries section in FCC, the more fun and creative bits.
I am pretty pleased that I manged to get the second certificate before my 100 days on Tuesday!
No comments:
Post a Comment