# Java Interview with a Microsoft engineer

#### Watch someone solve the k closest points problem in an interview with a Microsoft engineer and see the feedback their interviewer left them. Explore this problem and others in our library of interview replays.

**Java interview with a Microsoft engineer: K closest points** - YouTube

[Java interview with a Microsoft engineer: K closest points](https://www.youtube.com/watch?v=KpIVsxswZLo)

### Interview Summary

**Problem type**  
K closest points

**Interview question**  
1) Find the K closest points to a vertex  
2) How would you modify the solution if the input was an infinite streak of points?

### Interview Feedback

**Feedback about Inventive Wind (the interviewee)**  
**Advance this person to the next round?**  
 No

**How were their technical skills?**  
3/4  
**How was their problem solving ability?**  
2/4  
**What about their communication ability?**  
3/4

> It was a pleasure interviewing with you. So as I mentioned, I would def advance you to onsites but I'm very on the edge of passing you for an offer. And with that I'm going with a weak no hire. Meaning you were almost there but not enough. Which also means that if others pass you then it's a pass. So as mentioned, I evaluate in 4 categories. Technical skills, Algorithms and Data structure knowledge, communication skills and problem solving. Some thoughts of that are below. Also, I would like to see you work faster at these problems. You weren't really at a point where the code worked before we ran out of time.
> 
> ... Overall you did well, just needed a little bit more work. Mainly in how fast you work through a problem. As you advanced, your expectation to finish the problem faster goes up.

**Feedback about Indelible Raven (the interviewer)**  
**Would you want to work with this person?**  
 Yes

**How excited would you be to work with them?**  
4/4  
**How good were the questions?**  
4/4  
**How helpful was your interviewer in guiding you to the solution(s)?**  
4/4

> I think how you conducted the interview was very helpful. I don't know how your approach lines up with other interviewers on this platform but this was one of the more helpful practice sessions I have had. I really do appreciate the feedback at the end with some tips for improvement as well as the insight into how you would conduct the real-world interview.

### Interview Transcript

**Inventive Wind:** Hello.  
**Indelible Raven:** Hi.  
... (Omitted for brevity)

### Code and Optimization Discussion

**Inventive Wind:** ...So, I guess...  
- Maintain the K lowest points with a priority queue.  
- Evaluate optimizations for distances and check conditions.

>  ... if you had K points that were equal to the vertex then you would obviously...

>  ... the big thing is I mean in Java typically static methods like this are typically not encouraged by most Java style guides...

### Conclusion

**Indelible Raven:** ...If this was a very hire/no hire decision, I would swing to a very weak no hire, which means I'm on the edge of saying hire or no hire.

**Inventive Wind:** ...this was very helpful, you're a good interviewer and I do appreciate the feedback. It's much more informative than basically any other way of practicing.
