Week 2 journal entry
Week 2 Journal Entry Recursion has been a difficult journey for me so far. I was introduced to recursion in a previous class, but coming back to it again is still challenging. Understanding base cases and visualizing how the code flows step-by-step takes a lot of practice and deeper understanding. One of the hardest parts for me is trusting that the recursive calls are actually moving toward the solution. Sometimes I understand what the code is supposed to do, but I still get stuck figuring out how the function “unwinds” and returns the correct value. It’s easy to make mistakes when the recursive logic is slightly off, and even small errors in the base case can cause infinite recursion or incorrect results. Tracing recursion step-by-step has been helping me slowly build confidence and understand the pattern behind the code. Another topic that I’ve been working on this week is Big-O notation, which has been helping me think about efficiency instead of just whether my program works...