Earlier quoted context omitted.
It's always these low pay jobs that have the sloppiest interview experiences
In at least parts of Europe, 70k-100k is pretty good for a mid/senior developer.
Many hard LeetCode problems are easy constraint problems
411–420 of 551 posts
Re: Many hard LeetCode problems are easy constraint problems
#412Any problem can be solved by a sufficient number of nested for loops. (if you have enough time)
Populate a 2d lookup array. $7,50 becomes arr[750] = [7,1,0,0,0,0] which represents [7x100,1x50,0x25,0x10,0x5,0x1]
With each loop check if the array entry exists, if so check if that number of coins is larger. [7,1,0... is better than [7,0,2...] because 8 is a better solution than 9!
Re: Many hard LeetCode problems are easy constraint problems
#413Earlier quoted context omitted.
Wait, what.. you did this as a take home for a position? Damn that looks excessive.
Yes. I put a ton of work into it. I had about 60 pages worth of notes. On inverse kinematics, FABRIK, cyclic algorithms used in robotics, A*/RRT for real-world scenarios etc. I was super prepared. Talked to the CEO for about two hours. Took notes on all videos I can find of team members on youtube and their company. Luckily the hiring manager called me back and levelled with me, nobody kept him in the loop and he fel…
This never happened to me in a job interview before I turned 40. But once I knew I was too old to look the part, and therefore and had to knock it out of the park, mind blank came roaring in. I have so much empathy now for anyone it ever happened to when I was giving the a job interview. Performing under that kind of pressure has nothing to do with actual ability to do the job.
Re: Many hard LeetCode problems are easy constraint problems
#414Earlier quoted context omitted.
Many interviews now involve automated exercises on websites that track your activity (don't think about triggering a focus change event on your browser, it gets reported). Also, the reviewer gets an AI report telling it whether you copied the solution somewhere (expressed as a % probability). You have few minutes and you're on your own. If you pass that abomination, maybe, you have in person ones. It's ridiculous wha…
"don't think about triggering a focus change event on your browser, it gets reported)." So .. my approach would be to just open dev tools and deactivate that event. Show of practical skill or cheating?
Re: Many hard LeetCode problems are easy constraint problems
#415I would be blown away if a candidate solved it using DP and then said “but let me show you how to use a constraint solver”. Immediate hire.
Re: Many hard LeetCode problems are easy constraint problems
#416Earlier quoted context omitted.
It’s not about memorizing individual problems per se, but rather recognizing overall patterns and turning the process into a gameable endeavor. This can give candidates an edge, but it doesn’t necessarily demonstrate higher-level ability beyond surface familiarity with common patterns and the expectations around them. I’d understand the value if the job actually involved work similar to what's reflected in leetCode s…
>a candidate’s willingness to invest time and effort I guess it's a matter of opinion but my point is, this is probably the right metric. Arguably, the kind of people who shut up and play along with these stupid games because that's where the money is make better team players in large for-profit organizations than those who take a principled stance against ever touching Leetcode because their efforts wouldn't contrib…
Re: Many hard LeetCode problems are easy constraint problems
#417Earlier quoted context omitted.
To play the devils advocate, being able to memorize patterns and recognize which patterns apply to a given problem is extremely valuable. Tons of software dev is knowing the subset of algorithms, data structures, and architecture that apply to a similar problem and being able to adapt it.
It's funny you mention that. That's literally what CS teaches you too. Which is what "leetcode" questions are: fundamental CS problems that you'd learn about in a computer science curriculum. It's called "reducing" one problem to another. We had an entire semester's mandatory class spend a lot of time on reducing problems. Like figuring out how you can solve a new type of question/problem with an algorithm or two tha…
Then comes the ability/memorization to actually code it, e.g. if I knew it needs coding red-black tree I wouldn't even start.
Re: Many hard LeetCode problems are easy constraint problems
#418Earlier quoted context omitted.
"don't think about triggering a focus change event on your browser, it gets reported)." So .. my approach would be to just open dev tools and deactivate that event. Show of practical skill or cheating?
Switching to devtools also triggers a focus change and is detectable by other means (such as repeatedly invoking a debugger statement).
But probably a general solution exists ... and there are actually extensions that will do that in general.
Re: Many hard LeetCode problems are easy constraint problems
#419The reason was that aboint 70% of candidates couldn't write a simple loop -- to filter those out. The actual solution didn't matter much, I gave a binary decision. The actual conversation matters more.
Re: Many hard LeetCode problems are easy constraint problems
#420Earlier quoted context omitted.
At least personally, I've been very underwhelmed by their performance when I've tried using them. Usually past a few dozen variables or so is when I start hitting unacceptable exponential runtimes, especially for problem instances that are unsatisfiable or barely-satisfiable. Maybe their optimizations are well-suited for knapsack problems and other classic OR stuff, but if your problem doesn't fit the mold, then it's…
I'm surprised to hear this. Modern SAT solvers can easily handle many problems with hundreds of thousands of variables and clauses. Of course, there are adversarial problems where CDCL solvers fail, but I would be fascinated if you can find industrial (e.g. human written for a specific purpose) formulas with "dozens of variables" that a solver can't solve fairly quickly.
It usually starts taking a few seconds around the ~150-variable mark, and hits the absolute limit of practicality by 350–800 variables; the number of clauses is only an order of magnitude higher. Perhaps something about the many dependencies in a DFA graph puts this problem near the worst case.
The annoying thing is, there do seem to be heuristics people have written for this stuff (e.g., in FlexFringe [1]), but they're all geared toward probabilistic automata for anomaly detection and similar fuzzy ML stuff, and I could never figure out how to get them to work for ordinary automata.
In any case, I eventually figured out that I could get a rough lower bound on the minimum solution size, by constructing a graph of indistinguishable strings, generating a bunch of random maximal independent sets, and taking the best of those. That gave me an easy way to filter out the totally hopeless instances, which turned out to be most of them.