News for hackers. Stuff that matters.
Re:Show HN: AlgoDaily – One-a-day programming challenges for... by gatherhunterer on Sunday March 17, 2019 @06:06PM (#19416995)
The second question says "Select the proper order" but only lists single options, then when I clicked (thinking I was supposed to rearrange them) it just showed me the answer. From what I can tell it cannot be marked as correct or incorrect like the others. The use of the word "select" is confusing in that case.

While I realize these are toy problems, I would stay away from using "==" in an interview (or at all, unless you are contributing to a codebase that uses it). The reason is pretty clear from looking at the equality diagrams[1,2]. If you use "==" in an interview you should expect to be asked questions about how it works.

Will this evaluate to true? ( [1] == true )

How about this? ( [0] == true )

This one? ( [] == true )

This one? ( [[]] == true )

This one? ( undefined == null )

I would rather not spend my time in an interview talking about the JavaScript equality operator's Bizzaro World counterpart.

1. === chart https://i.stack.imgur.com/62vxI.png

2. == chart https://i.stack.imgur.com/35MpY.png

Re:Show HN: AlgoDaily – One-a-day programming challenges for... by sciencewolf on Sunday March 17, 2019 @07:26PM (#19417462)
Thanks! Those are great points.

The hint mechanisms could definitely be worked on. I'll be building a component that lets you click to choose order.

And yeah, the part about the equality operator is something I hadn't considered, but you're absolutely right that you don't want that to be the focus of your interview.