4 ms·
I disagree partially. With enough practice you will be good in leetcode, though if you knew also math it would probably be easier for you. But as far as I am I
by worldsavior 2y ago
I disagree partially. With enough practice you will be good in leetcode, though if you knew also math it would probably be easier for you.
But as far as I am I don't believe there is any math in algorithms such as bubble sort.
- JohnFen 2y agoSorting itself is a mathematical operation. It's part of set theory, specifically order theory. The entire algorithm is a mathematical expression.
- anomaloustho 2y agoI really want this general concept to be true from a “practicality sense” but am having trouble seeing it. Expressed as a mathematical expression. Given a problem that arrives at timsort with galloping mode as the solution, how would you hear the initial problem, and then express the solution as timsort in order theory? It feels like it would be awesome to do but also doesn’t feel like the logic of the algorithm would quickly be found simply by knowing order theory.