Live data from Hacker News

Ask HN: How to prepare for a Front-end Developer interview?

news.ycombinator.com

71–80 of 146 posts

Re: Ask HN: How to prepare for a Front-end Developer interview?

#74

Here are a few questions/problems I was asked in from-end interviews a couple months ago: Write a function that accepts an array of ints and a target number. If two of the numbers in the array can add up to the target, return their indices. (aka Two Sum) Write a function that accepts an int x and prints a spiral of "#"s so that the number of "arms" in the spiral equals x. Write a function that accepts a month and a y…

>>The good interviewers, IMO, gave me a "take-home" problem of building some mini front-end app that hit an API, and the really fun one involved reverse engineering an unpublished API - that's how I got my current job.

I agree with you, but whenever this subject comes up, a lot of folks here on HN complain that they have full-time jobs and families and don't have time for "take-home" questions.

Re: Ask HN: How to prepare for a Front-end Developer interview?

#75

I'm a front-end dev going through the hiring process right now. Here's a list of some of the questions I have been asked in technical interviews: - What is a clojure? - What is a callback? - What is an IIFE? - How can you use scope to keep a copy of i in a loop? - What is going on when you click a link to go to a website? - Difference between classical inheritance vs prototypical - Difference between object-oriented…

you meant closure ?

No he's from the UK. He meant clousure

Re: Ask HN: How to prepare for a Front-end Developer interview?

#76
post #12

Earlier quoted context omitted.

> Even for a front-end developer you should have a basic knowledge of data structures like linked lists, binary trees, min/max heaps, depth/breadth first search, tries, recursion, hash tables, etc. I would never care about these if I was specifically hiring a front-end dev. I've never once seen any of them come up in the context of front-end work in my entire career. And in fact an interviewer asking questions about…

I don't understand how that's possible. For example, in a recent project I needed to implement a path-finding algorithm to draw connections routed around arbitrarily-placed boxes. More recently, efficiently snap a line to the nearest edge from an in-memory set of (again, arbitrarily placed and changing) objects as the mouse moves. I'm having to use and think about some item from that list on a daily basis. Where's th…

I think OP's list of essential algorithms is a bit too long. I agree that knowing what a binary search is, or graph traversal, is something that everyone writing code should know, and something that does come up reasonably often. (And recursion, heh.)

But binary trees? Last time I needed them was in a CS class. Linked lists? They only came up when I had to convince a coworker that we really don't need to implement one in JS, we only have 50 items here, and someone is going to forget to update a linked list if we use one.

Re: Ask HN: How to prepare for a Front-end Developer interview?

#77

You should at least be familiar with the major front-end libraries and frameworks - React, Angular and Ember. You don't necessarily need to "know" them, but at least know about them. You should be familiar with what ES6 is and what Babel does. These technologies probably won't be specific questions per se but if they come up and you can't speak about them, it'd be a red flag. Even for a front-end developer you should…

Can somebody provide a real example of where you'd need to use "linked lists, binary trees, min/max heaps, depth/breadth first search, tries, recursion, hash tables, etc" in your typical everyday front end angular/react/ember project?

Depth-first and breadth-first graph traversal does come up. Example: you're implementing a task tracking system, where tasks can have dependencies. Boom, that's a graph. You want to display a whole graph of dependencies of a task (and dependencies of dependencies, etc.). Boom, there's graph traversal. You need to limit the number of tasks displayed in that graph, because someone added a thousand dependencies somewhere and now the graph rendering is choking up. Boom, traverse breadth-first and stop displaying more tasks after some preset number. This is an actual issue I ran into in actual code.

Now, about most of the other things that were mentioned… I'm not convinced.

Re: Ask HN: How to prepare for a Front-end Developer interview?

#79

Most modern production quality software systems there days are implementing fibonacci algorithms as part of their core business rules, controlled via a red/black tree. Usually it's held together by a fizzbuzz architecture so as a minimum you should be able to whiteboard fizzbuzz. You should understand all these things well, and really if you are doing modern software development these things hould be day to day tasks…

I know you've written it as satire but this is so real for me. The struggle is real.
Post reply on HN