Live data from Hacker News

Data Structures for Coding Interviews

interviewcake.com

31–40 of 238 posts

Re: Data Structures for Coding Interviews

#31

Earlier quoted context omitted.

Your explanations were excellent. I especially liked the way you introduced hash tables using a simple array where the indices had special meaning. The diagrams are clear and helpful. Only nitpick: not sure how somebody who is supposed to learn what an array is by reading this is supposed to already know the meaning of Big O notation. So maybe a little intro to Big O complexity somewhere in there would help as well.

Eep! Did you notice that the first time we mention big O notation, you can click on it and an inline explanation slides down? Probably not, based on the question! We should make that part louder.

As another data point, I thought the big O inline expansion was pretty clear, and clicked on it.

Re: Data Structures for Coding Interviews

#32
This is a good cheat sheet for those who don't have (or have forgotten) the knowledge but want to game an algorithm heavy interview. The problem I got with this is exactly the same as when I tried reading the "Cracking the Coding Interview" book:

I got through a few chapters and then the author mentions something off the cuff with an assumption that the reader will know what they mean. But of course, I don't, because these books are basically a collection of cheats and hacks. I get frustrated that I don't understand it, so I seek out something that starts with the fundamentals and expands from there.

What I'm trying to say is that I'd rather slog through 900 pages of Sedgewick and come out with a thorough understanding rather than try 20 quiz questions to be stumped by whatever the hell they were trying to get at with question 21 and then give up.

Re: Data Structures for Coding Interviews

#34

Earlier quoted context omitted.

Your explanations were excellent. I especially liked the way you introduced hash tables using a simple array where the indices had special meaning. The diagrams are clear and helpful. Only nitpick: not sure how somebody who is supposed to learn what an array is by reading this is supposed to already know the meaning of Big O notation. So maybe a little intro to Big O complexity somewhere in there would help as well.

Eep! Did you notice that the first time we mention big O notation, you can click on it and an inline explanation slides down? Probably not, based on the question! We should make that part louder.

The problem with links is that you don't know where they are going to take you. When I have such a nice piece of text to read I don't want to click and potentially land in a completely different site, have to click "back" and all that distracting stuff. That's probably why your link didn't "register" with me. In your case in turns out the link nicely expands in place, so that's pretty cool. I'd still just inline that little explanation on Big O, since you keep referring to it in the rest of the text. It's more than a mere footnote.

Now this is all my own experience, and others may disagree, so don't necessarily go changing things just on my account!

Re: Data Structures for Coding Interviews

#36
post #32

This is a good cheat sheet for those who don't have (or have forgotten) the knowledge but want to game an algorithm heavy interview. The problem I got with this is exactly the same as when I tried reading the "Cracking the Coding Interview" book: I got through a few chapters and then the author mentions something off the cuff with an assumption that the reader will know what they mean. But of course, I don't, because…

CEO of Interview Cake here. We work really hard at trying to not do this.

Feedback on where folks get left behind is pure gold to us, because it lets us know what we need to smooth out next. We're not trying to be the /biggest/ resource out there--we're trying to be the /smoothest/.

For this article, do you remember where specifically you got left behind?

Re: Data Structures for Coding Interviews

#37

> Don't worry—we'll skip the convoluted academic jargon and proofs. Aaaaand this is why I hate using this as a method for interviewing. I actually care a great deal about people that care about that stuff. I would rather you know all the principles and can reason your way back up, however slowly, than repeat something you've practiced enough for an interview. I understand the author really only wants to help people,…

I interviewed at some of these companies that liked the puzzles and so on. Then got to a company that actually seemed interested in stuff I've done before and asked enough details to know that I knew the stuff. I learned about what they did and seemed interested and got the job.

Puzzles and tricks are like that are a crutch, because people don't know how to talk and find out about what the other person knows.

Usually what happens if a company becomes successful is they codify whatever they did to get there in stone and that becomes "the golden process" by which everything must be one. If they hired people who knew how invert a binary tree or some stuff like that, they assume they become successful because of it. I would usually think they became successful in spite of it.

At the end of the day there are people who will sit and drill interview questions for months and years and maybe that's what companies want, people who are desperate enough to do that work. Maybe that's what the tests really test for ...

Re: Data Structures for Coding Interviews

#38
post #9

> Don't worry—we'll skip the convoluted academic jargon and proofs. Aaaaand this is why I hate using this as a method for interviewing. I actually care a great deal about people that care about that stuff. I would rather you know all the principles and can reason your way back up, however slowly, than repeat something you've practiced enough for an interview. I understand the author really only wants to help people,…

It's unfortunate, but all the companies are doing this. Here's what a Google lead said in a tweet: > Hello, my name is Tim. I'm a lead at Google with over 30 years coding experience and I need to look up how to get length of a python string. DHH: > Hello, my name is David. I would fail to write bubble sort on a whiteboard. I look code up on the internet all the time. I don't do riddles. Max Howell: > Google: 90% of o…

Ah, the perennial apologetics of weaponized mediocrity. If you can't write a simple recursive algorithm that swaps two values (Max Howell), two nested for loops (DHH), or show me that you used Python at least once (uhh length? yes, there is this builtin, I forgot its name...), why would I want to hire you over someone who has seen a computer before?

And to avoid being called hypocritical, here's off the top of my head how the answers would look like (I don't use Python very often either):

1. len(thingie)

2.

  def bubsort(arr):
    if not arr: return None
    for i in range(len(arr)):
      for j in range(i+1, len(arr)):
        if arr[i] > arr[j]: arr[i], arr[j] = arr[j], arr[i]
    return arr
3.

  def revtree(node):
    if not node: return None
    node.left, node.right = revtree(node.right), revtree(node.left)
    return node
edit: works well for something coded on the toilet: https://gist.github.com/andreis/69a242330617b2a62753ce604e27...

Re: Data Structures for Coding Interviews

#40

Earlier quoted context omitted.

Thanks for the note. Definitely a great point. Not sure yet how we tier out our product, but tiered pricing is definitely the state of the art. We've been working on some /tech/ to enable tiered pricing in the meantime. The Site's all custom, and so far there's no notion of a "product" yet...just "paid" and "unpaid." Share your question re: where's Kaplan on this stuff!

Price seems expensive to me as well. In data science there is a similar site which has become pretty popular if you are interviewing in those top tech companies, but it is cheaper. As the guy above was suggesting, that data science site does personalized feedback and that justifies the high price. Otherwise, the way it is now, it feels like it should be priced similarly to CTCI.

What's the data science site!
Post reply on HN