10
donuts
7y

Tech interview prep on leetCode... I solved this but wanted to read the optimal solution. I check the Solution page..... 😟 🙁 ☚ī¸ đŸ˜Ŗ 😖 😖 đŸ˜Ģ 😩 😩 đŸ˜Ļ 😧 😮 đŸ˜Ŧ đŸ˜Ŧ đŸ˜ĩ

https://leetcode.com/problems/...

The way I solved it, basically just did a merge of the 2 lists as is iterates thru them...

Ialright i need a break after i try to understand this...

btw, tech/CS workers, when you approach a real problem do you think like this? Solve the problems in Big O and math symbols?

Comments
  • 1
    @fuck2code so how do you understand this like conceptually/English. i cant understand the explanation in the Solution. You have 2 Sorted lists and somehow you can use binary search to find the mid.

    Usually i think, how would i do this manually. And the solution is merge them both.

    And then I realize i only need to check the middle values so I only have to merge until i reach half the total length.
  • 1
    But the other question i had was like at Google, Apple, tech companies, is this what the source code looks like... and the documentation?
  • 2
    @billgates I also go with my intuition and how I would solve it manually and try to implement that.
    Apparently that's not enough 😞
  • 1
    This looks cool. Ill have a look later :)
  • 1
    @c3ypt1c sorry I ruined a nice #
  • 3
    If I need this kind of math I use the wrong approach, language or I'm doing something wrong in general.
    There was once something we call KISS. I feel like as soon as there is an interview or a math teacher around we completely forget this.

    Artificial complexity I would call it. Problems designed to be completely stupid complex (which isn't a bad thing) without any consideration if the problem has a real-life use even (which is a bad thing)
  • 2
    @daintycode yes my biggest complaint is that you'll never this on the job units you're an algo designer and well I have no interest in being one...
Add Comment