r/java • • Jan 23 '21

Interview with Brian Goetz, Java Language Architect

https://freecontent.manning.com/interview-with-brian-goetz/
190 Upvotes

19 comments sorted by

View all comments

26

u/Roachmeister Jan 24 '21

For example, take red-black trees. How do they work? Most of the time, I shouldn’t have to care. If you need one, every language has an excellent pre-written, well tested, high performance library that you can just use. The important skill is not being able to recreate this library, but knowing how to spot when you can use it profitably to solve a bigger problem, whether it is the right tool, how this will fit into the time or space complexity of your overall solution, etc

And that is exactly why I never ask anyone to implement basic data structures in interviews. Nor would I want to work with anyone who does (unless the work was designing language features).

14

u/DasBrain Jan 24 '21

A better question would be:
"You want to do X, what data structure/java class would you use and why?"

That's still a hard question, but might be actually better to judge someone.

An answer like "I would use an ArrayList, because that's what I always use" would be ok, but not great either.

5

u/Roachmeister Jan 24 '21

A better question would be: "You want to do X, what data structure/java class would you use and why?"

Exactly!

1

u/GlowingYakult Jan 27 '21

You have a potential to be an interviewer or HR specialist lol