r/learnprogramming • u/Temporary-Warthog250 • Apr 05 '22
Name one programming/comp sci concept you never understood and if you understand it, try to explain it to them
Name a programming concept such as virtual functions, pointers, certain algorithms, etc that you always had a hard time understanding and why.
Someone else who reads yours and does understand it, try to explain it to them to help them learn
1.6k
Upvotes
2
u/Sexual_tomato Apr 06 '22
From my understanding, dynamic programming is the act of caching results of a function call or operation for simple subsets of a problem that overlaps finding an optimal solution to a harder overarching problem, like finding the shortest path between two nodes in a weighted graph. My personal interaction with it comes from the class I took in control theory when I got my engineering degree, but I just called it "don't waste time computing stuff I've already computed otherwise the Matlab code takes all night to run."
That being said, thank you for your really detailed explanation, and I appreciate your willingness to outline all the inaccuracies I glossed over.
I'm aware of all the points you made, and I realize that it painted my understanding in a bit of a dubious light. But, given that I typed all that out on my phone, it was time to get off the toilet, and this is a thread regarding the total lack of basic understanding, I figured the extra nuance would be too much noise. Imo, you adding the extra context in a separate comment is a better way to read it anyway :)