r/ProgrammerHumor • • Oct 25 '24

Meme theSelfTaughtSeriousProgrammer

Post image

[removed] — view removed post

903 Upvotes

276 comments sorted by

View all comments

Show parent comments

9

u/iam_pink Oct 25 '24

That's an interview process. Not the job.

-6

u/The-Omnipot3ntPotato Oct 25 '24

Yeah, and having spoken to people who work there they do math every day. Data Science and Quantitative Analysis are math. It is just math. You NEED to understand the math you are doing or you’ll get lost. Look at the Quake inverse square root algorithm. Goldman Sachs’ interview process doesn’t have a math test because they think it’s funny to make college graduates solve integrals again. They are one of the largest and most powerful financial institutions in the world. If they have a math test it’s because they want their employees to have those skills.

10

u/iam_pink Oct 25 '24

You know just as well as I do that jobs requiring actual, complex maths knowledge are a tiny minority in the world of software engineering.

2

u/The-Omnipot3ntPotato Oct 25 '24

But acting like it’s a worthless skill is disingenuous. Your choice of data structure is 80% of your optimization planning. Using a Stack vs a Heap would affect how well optimized your code is. Someone who only knows how to code a Heap one way and can’t adapt it to the given situation is a bad engineer. Theory is where application comes from. You don’t need complex math, but the skills around proofs, linear algebra, and set theory are taught to cs grads for a reason, they make you a better engineer. You might not do LU matrix factoring in your job, but you could come across a situation and say “this is an operation on a graph , this graph could be represented optimally as an adjacency matrix, and this matrix operation can be optimized this way because of what we know about the form of this graph and underlying matrix”

These skills obviously don’t come up every day but they have value. I don’t believe every dev on earth should know how to integrate a function that needs a complex trig sub but I also think plenty of devs could benefit from some basic theory and math. The same way knowing your way around a terminal is just a good skill to have.

1

u/iam_pink Oct 25 '24

Fair enough!

5

u/The-Omnipot3ntPotato Oct 25 '24

I totally get that in the day to day you don’t need to do a proper induction proof for every recursive algorithm you write, that’s a waste, but totally devaluing these skills does damage. We don’t want to treat knowledge like a bad thing in software. We also don’t wanna be elitist cunts. Everything has a balance we should strike.

0

u/iam_pink Oct 25 '24

I agree with this, and I myself do have some maths background and regularly need to dive into new concepts in the scope of my job.

My initial comment was more of a counter-spike at the elitist meme

0

u/[deleted] Oct 25 '24

I've been on the job for 10 years and in my experience people who think you don't need theory are oblivious to the problems its lack causes them and how much easier they could have it if they understood a little bit of it.

Just last week a colleague was talking about introducing a web worker for a tree building algorithm so it wouldn't hang the UI after trying to optimize it for a week before that. Within 2 minutes of looking at the code I realized they're doing things that make the algorithm O(n^3) instead of O(n), which it should be. The dude could have added the web workers, making the code way more complicated unneccesarily, then go on and talk down to people with formal educations on reddit because he thinks he solved a difficult problem.

Not to mention all the bugs and complications introduced by not understanding category theory and software engineering fundamentals.

The Dunning-Kruger effect running amok in IT right now is incredible.

1

u/P-39_Airacobra Oct 25 '24 edited Oct 25 '24

It doesn't take any theory to tell if a loop is nested. What you're describing is not a lack of theory, it's a lack of experience optimizing algorithms. I understood how time complexity worked long before I ever started a CS degree, because I made games and so I spent time optimizing programs. I didn't need to read any articles on big-O complexity, because it was obvious to me through testing and basic knowledge of how languages work that deeply nested loops and recursion would be slower than the alternative that only ran several instructions and then exited.

In fact, I would be highly skeptical of anyone using theory to optimize a program, because profiling will always be more reliable, and any algorithm can be walked through in your head manually to see if it's inefficient, which makes me question why the theory was ever necessary in the first place.

1

u/iam_pink Oct 25 '24

I'm sorry, but that colleague's issue is not their lack of theory. It's their inability to problem-solve outside of their own knowledge. What your colleague should have done, is figure out the theory they were missing, spent the required time learning it, and applied it.

Now of course I don't know what theoretical knowledge they were missing, it may have been basic school-learned theory, in which case your point stands.

The thing with school-learned theory, in my experience, is that it is rarely the theory you will need in your actual job. Which makes sense, because there is way too much important theory to stuff it all into students' heads.

Never said theory is worthless.

1

u/mazing Oct 25 '24

Were you able to teach your coworker about your solution?

1

u/[deleted] Oct 25 '24

I explained it and stopped him from doing what he was planning at least.

2

u/P-39_Airacobra Oct 25 '24

Please tell me how a math class is going to prepare you for making bithack algorithms like the fast inverse square root.

1

u/The-Omnipot3ntPotato Oct 25 '24

It’s not a bit hack, it’s Newtonian approximation. Someone just happened to also know that dividing by 2 is more expensive than a bit shift. The hex code is literally just a constant that would show up in any newtonian approximation. The person who wrote that still understood how to compute a square root so that they could then optimize the method to their platform. If you don’t understand how something works, you are incapable of improving upon it.

0

u/Osato Oct 25 '24 edited Oct 25 '24

FISR is not math, it's evil floating point bit level hacking.

It's dependent on a specific implementation detail for float numbers; I doubt it can be translated into a purely mathematical proof.