# Python Interview with a Google engineer

#### Watch someone solve the partition array and public transportation problem in an interview with a Google engineer and see the feedback their interviewer left them. Explore this problem and others in our library of interview replays.

Python interview with a Google engineer: Partition array and public transportation - YouTube

[Python interview with a Google engineer: Partition array and public transportation](https://www.youtube.com/watch?v=BFKbbE9Tpqs)

### Interview Summary

**Problem type**  
Partition array and public transportation

**Interview question**  
1) Check whether it is possible to partition an array.  
2) Is there a way to get from one city to the other with the given bus routes?

### Interview Feedback

**Feedback about Rocket Tiger (the interviewee)**  
Advance this person to the next round?  
Yes  
How were their technical skills?  
4/4  
How was their problem-solving ability?  
4/4  
What about their communication ability?  
4/4  
> Very good overall. Was able to identify a viable algorithm very quickly for pretty hard problems. Could probably improve by articulating at a higher level how the technique works. For example with DP, explain how the lookup table saves calculations vs a recursive approach. Also, take the liberty to shape your inputs how you want it (unless its a constraint of the question). For instance, with the bus problem, just declare that you are expecting input cities 0 - n if that makes life easier.

**Feedback about Electric Burrito (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 really appreciated the questions and thought you were a great interviewer. I also really enjoyed your active participation and enthusiasm as we went through the code and discussed ideas throughout the process.

### Interview Transcript

**Electric Burrito:** Hello.  
**Rocket Tiger:** Hi.  
**Electric Burrito:** How's it going?  
**Rocket Tiger:** Hello?  
**Electric Burrito:** Can you hear me?  
**Rocket Tiger:** Yeah I can hear you now.  
**Electric Burrito:** Okay well uh so um are you ready to interview?  
**Rocket Tiger:** Yeah go for it.  
**Electric Burrito:** Um okay so I presume you're going to be using Python 3.  
**Rocket Tiger:** Yeah.  
**Electric Burrito:** And so how long have you been... are you currently not like working? Are you um are you just like a recent graduate or have you been working as a developer?  
**Rocket Tiger:** Yeah so to give you a little bit of my background I've been working since graduation and that graduation was in spring, so I'm pretty much a new grad. So graduating 2018 spring, started around September, and using interview.io...

---  
...

**Rocket Tiger:** Okay so if we can assume that... so we need to figure out how many cities we have and so let's assume that we have simply processed... All numbers are continuous. So we need to find I guess some like small first step. So that'll get us the total number of cities. So ideally that should set up our initialized array so it'll look something like... right?  
**Electric Burrito:** Sorry what what is a max city? that's the root city?  
**Rocket Tiger:** So max city is just like the largest number that you have in your input so for instance if like the example that you pasted above it would be 8 right? All it's doing is just telling us how large our parent arrays should be.

---
