I was a mathematician, and now work in finance (systematic trading). I've found a reasonable negative filter is A jar has 1000 coins, of which 999 are fair and 1 is double headed. Pick a coin at random, and toss it 10 times. Given that you see 10 heads, what is the probability that the next toss of that coin is also a head? That tests their ability to turn a problem into mathematics, and some very basic conditional p…
That's a nice filter. (Of course, I'm a former mathematician as well.) Here's how I think of it: - the prior odds that you picked the double-headed coin are 1/999. - after seeing ten heads, the posterior odds that you picked the double-headed coin are (2^10)/999 - let's approximate this as 1. (Bayes' theorem usually gets expressed in terms of probabilities, but it's so much simpler in terms of odds.) - so it's roughl…
Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
291–300 of 363 posts
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#292Earlier quoted context omitted.
No thanks; I'm happy with the job I've got right now. But I appreciate you asking! More seriously, shouldn't it be possible to post a version thoroughly enough sanitized to avoid giving the game away to your potential applicants, without losing the sense of the original? You don't identify your organization in your HN profile, so it doesn't seem terribly likely anyone who's looking for hints on your hiring process wi…
I might see if I can come up with something approximating the test... The tricky part about making it so that people online could take it is that I'd need to give you an avenue to play around in a query editor and run queries on a database I've created. Short of making a publicly available database on my own domain (which uses a different database platform than what we use at work), is there a good way to accomplish…
I'd use the Web SQL Database stuff that W3C was working on, except that they stopped doing that in 2010, which guarantees the corpse is dead and rotting; unfortunately, the only emulation libraries I've been able to find implement various key-value stores on top of WebSQL, which is the precise inverse of what I'd need.
I suppose it'd be theoretically feasible, albeit hideously ugly, to create and populate a fresh database and account per user on a MySQL engine; with careful grants and a bit of scripting to kill slow queries before they can multiply and throttle the server, that might be workable on the small to medium scale, although I don't doubt a "Show HN" post would kill it in short order.
Thinking about it, I suspect I've more or less recapitulated why there is currently no "You Can't SQL Under Pressure"; it's a more subtle problem than it seems at first blush. If you come up with any clever ideas on the subject, I'd love to hear about them!
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#293Where I work, we have a 4 question SQL test where we sit you in front of a dummy database, give you 4 printed results, and say "make the queries to produce exactly these results." Very very few people get all of them, but it gives us an idea of where somebody is at in their ability and knowledge. The first is the easiest, and the second one isn't bad. The 3rd and 4th trip up most people though.
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#294I was a mathematician, and now work in finance (systematic trading). I've found a reasonable negative filter is A jar has 1000 coins, of which 999 are fair and 1 is double headed. Pick a coin at random, and toss it 10 times. Given that you see 10 heads, what is the probability that the next toss of that coin is also a head? That tests their ability to turn a problem into mathematics, and some very basic conditional p…
On the flip side, you could probably unintentionally trip up someone with a generally competent grasp of economics/stats but a lack of specific interest in bonds over terminology if your followup questions start asking them to distinguish between types of yield.
Same with exchange rates (although I do remember back in school in a competitive presentation being complemented on my confident and plausible sounding explanation of the effect of an interest rate rise on exchange rates that also happened to be the reverse of the correct answer :-) )
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#295Earlier quoted context omitted.
Probability is a fact about you, not a fact about the coin. Huh? It's a coin . You flip it. It has no knowledge of the past and no idea about the future. It lands and it's either heads 50% of the time and tails 50% of the time. It's all about the coin and nothing about what you've observed in the last N trials. That's the simple logic that the OP is trying to see if you understand.
It may be a useful sanity check to simulate the experiment multiple times to see the result: def choose_coin rand 0, :tails => 0 } 1000000.times do coin = choose_coin next unless all_10_heads? coin next_flip[flip_coin(coin)] += 1 end puts next_flip[:heads].to_f / (next_flip[:heads] + next_flip[:tails])
http://en.wikipedia.org/wiki/Probabilistic_programming_langu...
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#296Earlier quoted context omitted.
Yep, I worked at the company you're probably speaking about for 9 years (I say probably, because there are two...Walmart and JB Hunt). I just left Walmart 3 months ago, largely because I was ready for something new, and the place I work now is just a lot more cool. Big change for me, going from giant IT building to a company that has 25 people total. They had less than 20 when I applied and 9 people a year ago.
Well, I've never heard anything about JB Hunt's IT, for good or ill, so... That must be a weird change, yeah, but it sounds good on the whole. It's a shame the timing didn't work out on this; if I still lived in Memphis, I'd have jumped at the opportunity. (I didn't like living in Memphis very well -- Bentonville seems like it'd be much more congenial.)
I know a little bit about JB Hunt's IT. They use COBOL and Java. They might have some other stuff, but they seem big on those two from what I've heard.
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#297Based on interviews, POMDP has become a favorite FizzBuzz question for data scientists. So make sure you have a working example for that. I usually explain the tiger pot of gold in gruesome detail. https://www.google.com/search?q=tiger+pot+of+gold+pomdp
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#298Working for a web company. Our favourite JS question is, "What happens if you do this?" var func = function func () { // blah };
The variable declaration is hoisted to the top, then is assigned a named function expression `func` so that `func.name === 'func'`. Useful for proper error messages and stack traces. Something else I'm missing?
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#299Working for a web company. Our favourite JS question is, "What happens if you do this?" var func = function func () { // blah };
nothing? What answer are you looking for here? either a) there's something I'm totally missing or b) this is a really silly "trick" question.
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#300Earlier quoted context omitted.
It's supposed to be recursive. That would only delete the files in the current directory, not subdirectories as well.
-r is the 'recursive' flag.