I build web sites. I would ask that the person complete a series of tasks that involved using Javascript to do a bit a typical DOM manipulations and CSS changes, especially using transitions and whatnot... ...without jQuery.
Just curious, why do you not allow the interviewee to use jQuery? Do you expect the candidate to know JavaScript's DOM-level APIs without having to look them up?
Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
341–350 of 363 posts
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#342I build web sites. I would ask that the person complete a series of tasks that involved using Javascript to do a bit a typical DOM manipulations and CSS changes, especially using transitions and whatnot... ...without jQuery.
Just curious, why do you not allow the interviewee to use jQuery? Do you expect the candidate to know JavaScript's DOM-level APIs without having to look them up?
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#343I build web sites. I would ask that the person complete a series of tasks that involved using Javascript to do a bit a typical DOM manipulations and CSS changes, especially using transitions and whatnot... ...without jQuery.
Why?
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#344Working for a web company. Our favourite JS question is, "What happens if you do this?" var func = function func () { // blah };
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#345I build web sites. I would ask that the person complete a series of tasks that involved using Javascript to do a bit a typical DOM manipulations and CSS changes, especially using transitions and whatnot... ...without jQuery.
That's not really fizzbuzz, that's more the equivalent of asking a C programmer to write fizzbuzz in assembly (perhaps that's a little too strong a comparison, but you get the idea). Fizzbuzz for websites would be to have someone code two paragraphs side by side with a header and footer in CSS.
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 direction. To make a pattern like fizzbuzz I suppose I would do something more like: build a page with a series of paragraphs so that these CSS properties apply to every third paragraph, these CSS properties apply to every fifth paragraph, and so on. Something possible with CSS but requires the ability to think things through.
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#346Earlier quoted context omitted.
related problem: a population has a 10% incidence of condition X. A test exists that is 90% accurate. 1) What is the expected percentage of positive test results? 2) if a person tests positive, what is the probability that they actually have the condition? 3) if a person tests negative, what is the probability that they are actually free of the condition?
By "90% accurate", you mean "10% false positive rate and 10% false negative rate", correct?
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#347I 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…
1024/1025 * 1/1024 = 1/1025 (probability of unbiased coin, 10 heads) 1/1025 (probability of biased coin & 10 heads) relative probability = .5 the answer is then precisely 3/4
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#348Earlier quoted context omitted.
That's not really fizzbuzz, that's more the equivalent of asking a C programmer to write fizzbuzz in assembly (perhaps that's a little too strong a comparison, but you get the idea). Fizzbuzz for websites would be to have someone code two paragraphs side by side with a header and footer in CSS.
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…
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 guess, but I'd argue its overkill for basic websites, to be honest) I can guarantee you're farting around with the box model though, and odds are you could be using a framework to do it for you. Which is precisely why I'd want to test it.
Re: Ask HN: What's your speciality, and what's your "FizzBuzz" equivalent?
#349Earlier quoted context omitted.
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.
It's a good chance to show off your knowledge of hoisting.
I much prefer "Here's a domain problem, how would you solve it" to a vague question where the interviewer has a specific, hard to determine answer in mind. The former directly tests my ability to solve relevant problems, the latter just tests my ability to guess what the interviewer is thinking. In this case I'm perfectly aware of how variable & function declarations are hoisted in JS, but it wasn't clear to me that this was the answer sought- I know the answer but I don't know that's the answer being angled for so I fail at the question. Should this reflect badly on me? I am not sure- this sort of guessing skill may be what this interviewer is looking for. (?)