Live data from Hacker News

Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

news.ycombinator.com

351–360 of 363 posts

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#352

Earlier quoted context omitted.

If their primary task was to build HTML emails then I could understand that train of thought. I suppose there are people out there that are working as front-end developers for websites that only work in HTML and CSS, but I would think that's getting more rare as time goes on. Of course, that could just be bias based on my own career. But, going with your suggestion as a thought exercise, I would go in a different dir…

The point of fizzbuzz is that it is a ridiculously easy test that any programmer that says they "understand" a language should be able to do, because they would touch things like loops and str manipulation in pretty much every program they ever write. Nobody is going to color code repeating paragraphs in CSS on every project. You wouldn't use that javascript on every project either. (Perhaps these days you would I gu…

I believe I would say that knowing how to do fizzbuzz for the reasons you describe and knowing how to do what I described is much the same thing within their own area of expertise.

For what I would consider a basic website I'm doing a decent amount of CSS and JS work. But I suppose that could depend upon your definition of a basic website.

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#353
post #337

Quality Assurance (QA) engineer. I do QA Tools specifically but still need to be on top of most QA stuff. Other QA engineers exist in the company for in depth QA. My initial question starts with: "build a function that takes a string and produces an integer". About 30% of candidates fail to get anywhere. 50% produce an incorrect implementation. 20% produce an implementation that is mostly correct. 9% produce an imple…

This would match your specification. def string_to_int(str): return 1

[deleted]

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#354
post #337

Quality Assurance (QA) engineer. I do QA Tools specifically but still need to be on top of most QA stuff. Other QA engineers exist in the company for in depth QA. My initial question starts with: "build a function that takes a string and produces an integer". About 30% of candidates fail to get anywhere. 50% produce an incorrect implementation. 20% produce an implementation that is mostly correct. 9% produce an imple…

This would match your specification. def string_to_int(str): return 1

[deleted]

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#355
post #337

Quality Assurance (QA) engineer. I do QA Tools specifically but still need to be on top of most QA stuff. Other QA engineers exist in the company for in depth QA. My initial question starts with: "build a function that takes a string and produces an integer". About 30% of candidates fail to get anywhere. 50% produce an incorrect implementation. 20% produce an implementation that is mostly correct. 9% produce an imple…

This would match your specification. def string_to_int(str): return 1

That would match the initial specification. The point is for the candidate to note that the initial specification is too ambiguous and determine what they do about it.

If they gave that answer and then said "which is why the specification is weak" then great! If they gave that answer and called it done... well... not so good.

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#356
post #337

Quality Assurance (QA) engineer. I do QA Tools specifically but still need to be on top of most QA stuff. Other QA engineers exist in the company for in depth QA. My initial question starts with: "build a function that takes a string and produces an integer". About 30% of candidates fail to get anywhere. 50% produce an incorrect implementation. 20% produce an implementation that is mostly correct. 9% produce an imple…

This would match your specification. def string_to_int(str): return 1

[deleted]

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#357

Earlier quoted context omitted.

The funny thing is, I imagine I'd fail this, and a lot of other "interview" questions. (Not fizzbuzz incidentally :P) Why? Because my brain just doesn't seem to work in the way people expect "experts" brains to work in our world of tests/qualifications. Now for context, I don't consider my self some wishy washy "Oh I have a different KIND of intelligence" making-excuses dumb as nails nancy. I've worked several years…

So, to see if I understand you: * The person suggesting the question says that this is trivial for people suited to the job in mind; * You say you couldn't do this question; * You also say that you would be suitable to do the job. Given that the proposer of the question is the one that understands the job, I'm having a hard time understanding why you claim you would be suitable for it, given that you couldn't do the…

Do you talk to your mother with that mouth?

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#358
post #325
post #312

Earlier quoted context omitted.

True. I glossed over the crucial part, which is that you have to enumerate the same number of potential outcomes for the biased coin's ten flips as you do for each fair coin, because each coin is equally as likely to be selected from the jar. Of course, all 2^10 potential outcomes for the biased coin's ten flips are the same: all heads. So we have: 00000 00000 0 00000 00000 1 For 999 fair coins = 1998 And 2^11 instan…

... because each coin is equally as likely to be selected from the jar That's not the reason. It's because the fake coin also has two sides and therefore also 2^11 different outcomes. It just happens they all look the same. Otherwise I agree with your argument.

True, I could have still used zeros and ones to enumerate all outcomes of the biased coin, but said that both digits represent heads.

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#359

Earlier quoted context omitted.

"If you flipped 10 heads in a row the probability of the coin you have being the double heads coin increases dramatically..." I disagree. The coin is the coin. It didn't magically transport itself or change state after flipping it 10, 100, or a billion times. Lets change the puzzle to the simplest state: you pull a coin from the 1000-coin jar and flip it just once. What's the probability of heads? This is why roulett…

I think you're missing the point of the question which seems to get at whether the interviewee is familiar with/understands bayesian probability. For an excellent explanation you should see: http://yudkowsky.net/rational/bayes .

I don't see why knowledge of Bayesian probability is necessary for this question. I don't have anything more than a passing knowledge of Bayesian probability, but I was able to produce the correct answer and a reasonable explanation using what I believe to be classical probability: https://news.ycombinator.com/item?id=7001288

Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?

#360

Earlier quoted context omitted.

That probability was determined the moment you picked the coin out of the jar. It makes no difference what you do to it after the pick. Hold it in your hand for a day, flip it 10 times, sit on it, whatever - the end result is that p(heads) for that particular coin has not changed . p(heads) will be either 0.5 for a real coin or 1.0 for the rigged one. The probability then comes down to what coin you picked at the sta…

I think you are discussing different interpretations of probability (classical vs bayesian), which is causing the disconnect. http://en.wikipedia.org/wiki/Probability_interpretations

That's not really the problem. I believe I was able to explain the correct response using classical probability: https://news.ycombinator.com/item?id=7001288. This is no more complex than asking what the odds are of being dealt a full house in poker. You can enumerate all equally likely outcomes and simply count them.
Post reply on HN