Skip to main content

Posts

Showing posts from January, 2026

Learning Merge Sort and Graph Traversals

This week’s module focused on algorithm design and analysis, with a strong emphasis on divide-and-conquer techniques, especially Merge Sort . From the lecture video captions, I learned how Merge Sort works by repeatedly dividing an array into two halves until each subarray contains only one element. Since a single element is already sorted, the algorithm then focuses on the merge step, where two sorted arrays are combined by comparing elements one at a time. This helped me better understand why Merge Sort is efficient and reliable. I also learned how to analyze Merge Sort using a recurrence relation and apply the Master Theorem to determine its time complexity. By identifying the values of a , b , and f(n) , I was able to see why Merge Sort runs in Θ(n log n) . In addition, the homework and quiz strengthened my understanding of DFS and BFS traversals , including how traversal order and marking rules affect the final result. Topics like the Traveling Salesman Problem , Knapsack Prob...

CST 370 - From loops to Logarithms

This week’s lessons strengthened my understanding of how algorithm efficiency is measured using Big-O, Big-Theta, and Big-Omega notations . The lecture notes emphasized identifying the basic operation and using the dominant term to classify an algorithm’s growth order. Through quizzes, I learned why Big-Theta can only be used when an algorithm has the same time complexity in all cases, while Big-O represents an upper bound. The homework project applied these ideas in practice by showing how sorting often dominates overall runtime, leading to (n log n) complexity. Analyzing recursive algorithms using recurrence relations and backward substitution also helped clarify how time complexity evolves across recursive calls.

Thinking Like an Algorithm in CST 370 This Week

This week, I learned about several important concepts in algorithms and data structures. From the recorded videos, I learned how pseudocode is used to describe algorithms in a clear and language-independent way. I also learned about different problem types , such as sorting, searching, graph problems, and tree data structures. Topics like graphs with vertices and edges, the Traveling Salesman Problem, and trees such as binary trees and binary search trees helped me understand how real-life problems can be modeled using data structures. The quizzes helped reinforce ideas like basic operations, time complexity, stable sorting, and graph properties. One aha moment for me was understanding how binary search trees make searching efficient . By comparing values and choosing to go left or right, the search space becomes smaller very quickly. Another important realization was how sorting can improve searching performance, which explains why these two topics are often discussed together. I al...