Posts

Showing posts from February, 2026

CST 370-30 - Algorithm Design & Analysis Week 7

Week 7 Learning Journal -  This week focused on advanced algorithm design techniques including non comparison sorting, dynamic programming, and graph algorithms such as Warshall’s and Floyd’s algorithms. I learned how algorithm efficiency changes depending on the approach used. For example, Counting Sort achieves linear time by avoiding comparisons, and Dynamic Programming reduces repeated computation through optimal substructure. In our group bonus project, we also applied algorithmic efficiency principles. For example, we used an unordered_map for fast keyword searching with average constant time lookup. We also used a priority_queue to efficiently rank bookmarked verses. Even though we did not actually code dynamic programming or graph algorithms in our project, working on it still made me think more about why choosing the right data structure matters. When we picked unordered_map and priority_queue, I could clearly see how much easier and faster certain operations became compar...

CST 370-30 - Algorithm Design & Analysis Week 6

Week 6: This week focused on balanced search structures and priority based structures. At first AVL trees were confusing, especially keeping track of balance factors after each insertion. After doing several rotation examples, I started noticing patterns in the cases instead of just memorizing steps. Some insertions only needed a quick fix, while others required adjusting two levels of the tree. It started to make more sense when I followed the height updates step by step from the leaf up to the root. After that, 2 3 trees felt like a shift in thinking because instead of rotating nodes, the structure avoids imbalance by storing more than one key in a node. That contrast helped me see that both methods are trying to keep searches fast, just in their own way. Heaps and heapsort clarified how the heap property supports efficient removal of maximum elements and sorting in place. Finally, hashing introduced constant time access ideas, along with handling collisions and load factor considera...

CST 370-30 - Algorithm Design & Analysis Week 5

Week 5: This week focused on core algorithm design ideas and how they are applied in practice. I learned how Quick Sort works step by step. Particularly how partitioning affects performance and why the median of three approach helps reduce worst case behavior. The binary tree lectures helped me clearly understand preorder, inorder, and postorder traversal, along with how tree height is calculated. Decrease and conquer made binary search easier to reason about by breaking problems into smaller parts. I also learned how DAGs and topological sorting work, with Kahn’s algorithm showing a clean and logical process. Pre sorting showed how preparation can simplify complex problems. The materials this week connected theory with real algorithm behavior in a clear way.

CST 370-30 - Algorithm Design & Analysis Week 4

Week 4 This week we learned MergeSort and divide and conquer. We split the array into smaller parts until there is one element and then merge everything back in order. Once I followed the steps slowly it made sense. MergeSort always runs in Theta n log n which makes it efficient. While reviewing for the midterm I realized I messed up because I rushed. I missed questions about when Theta notation can be used, how to count comparisons in recursive functions, and how backward substitution works. Getting those wrong showed me I need more practice and I need to slow down during exams instead of guessing when I don't fully understand something.