The value in understanding algorithms from a theoretical perspective

academics algorithms computer science
By Will O.

Computer science majors across many universities often dread their introduction to algorithms course, especially if it is proof-based. It can feel out of place compared to the rest of their classes that focus more on learning standard coding practices, the fundamentals of how computers work, or just generally courses that seem to directly prepare students for becoming software engineers. What’s the purpose of a proof-based algorithms course that feels more like a math than computer science class? 

Easy Answer: Preparation for Technicals Interviews

Most tech companies will require a technical interview before they hire you for either a full-time position or an internship. The usual structure to these interview questions is that the candidate is given a moderately challenging algorithm question, which they take some time to try to solve theoretically. The candidate then explains their solution to the interviewer before actually implementing it in code. 

It’s easy to guess that a mathematical understanding of algorithmic principles would be helpful for this, but I’ve also seen evidence of this demonstrated countless times. For example, when I was a freshman at Caltech, the only two freshmen in my class who received internship offers from Google were both dual math and computer science majors who had already taken a theoretical CS course. They were well prepared for recognizing which algorithmic approach, such as dynamic programming, greedy, divide and conquer, etc. was best for the interview questions and could explain why it works, reason about runtime, and understood the algorithm deeply enough to implement it correctly.

Deeper Answer: Solidifying Fundamentals 

It is quite possible to be a good programmer without being able to prove why an algorithm is correct, but anyone looking to truly be a master in the field should surely be able to understand and argue about the correctness of any algorithm they use. When you just take for granted the algorithms and packages of other engineers, you aren’t really in control of your code. 

Writing proofs is like shooting free throws, perfecting brush strokes, or practicing chords. It solidifies your fundamentals. A lot can change from one programming language to another, but the underlying structure and correctness of an algorithm does not. Thus a theoretical understanding of algorithmic principles gives you the necessary skills to be creative in your code and not just rely on what exists from others. Although it may be a challenging course, you should appreciate a proof-based algorithms course for teaching you the fundamentals and deepening your understanding of computer science as a whole.

Will is now attending Stanford’s Graduate School of Business for his PhD, studying applications of machine learning, algorithms, and network science to problems in business. He previously double majored in computer science and mathematics at Caltech.


academics study skills MCAT medical school admissions SAT expository writing college admissions English MD/PhD admissions writing LSAT GMAT strategy GRE physics chemistry math biology graduate admissions ACT law school admissions test anxiety interview prep language learning academic advice MBA admissions premed personal statements homework help career advice AP exams creative writing MD study schedules Common Application summer activities test prep history computer science philosophy organic chemistry secondary applications supplements economics PSAT admissions coaching grammar mathematics research law statistics & probability psychology 1L ESL CARS SSAT covid-19 dental admissions legal studies logic games reading comprehension USMLE engineering Spanish calculus parents Latin verbal reasoning DAT PhD admissions case coaching excel mentorship political science AMCAS French Linguistics MBA coursework Tutoring Approaches academic integrity chinese medical school Anki DO English literature Social Advocacy admissions advice algebra astrophysics biochemistry business classics diversity statement genetics geometry kinematics mental health presentations quantitative reasoning skills study abroad time management work and activities IB exams ISEE MD/PhD programs STEM adjusting to college algorithms art history artificial intelligence athletics business skills careers cold emails data science functions gap year international students internships letters of recommendation logic mechanical engineering poetry resume science social sciences software engineering tech industry technical interviews trigonometry 2L 3L AAMC Academic Interest DMD EMT FlexMed Fourier Series Greek Health Professional Shortage Area Italian Lagrange multipliers London MD vs PhD MMI Montessori National Health Service Corps Pythagorean Theorem Python Sentence Correction Step 2 TMDSAS Taylor Series Zoom acids and bases amino acids analysis essay architecture argumentative writing art art and design schools art portfolios biomedicine brain teaser campus visits cantonese capacitors capital markets cell biology central limit theorem centrifugal force chemical engineering chess chromatography class participation climate change clinical experience community service constitutional law consulting cover letters curriculum dementia demonstrated interest dental school dimensional analysis distance learning electric engineering electricity and magnetism enrichment escape velocity european history executive function finance first generation student freewriting fun facts genomics graphing harmonics health policy history of medicine history of science hybrid vehicles hydrophobic effect ideal gas law induction infinite information sessions institutional actions integrated reasoning intern investing investment banking lab reports linear algebra linear maps mandarin chinese matrices mba medical physics meiosis microeconomics mitosis music music theory neurology neuroscience office hours operating systems organization pedagogy phrase structure rules plagiarism potential energy pre-dental proofs pseudocode psych/soc qualifying exams quantum mechanics relativity