Reposted
Google · Phone screen
In processGoogle New Grad R1 Valid Tree From Parent Array: 1 Experience
Software engineer · New GradMaster's degreeFeb 2026
Shared by
Google new grad SWE R1, February 2026: decide whether a parent array forms one valid tree, checking root count, cycles and reachability; passed.
At a glance
- Process: R1 coding interview → passed (01).
- Asked recently: validate a tree given as a parent array (01).
- Practise first: Validate a Tree From Its Parent Array
Coverage: one Google software engineer new grad candidate; report February 2026.
What came up
| Topic | Reports | Last seen |
|---|---|---|
| Trees and graph traversal | 1 of 1 | Feb 2026 |
Questions we found
Algorithms / Data Structures
| Question | Reports | Last seen |
|---|---|---|
| Validate a Tree From Its Parent Array | 1 | Feb 2026 |
1 detailed candidate timeline
01: One root, no repeats, everything reached
Report date: February 2026 · Role: Software Engineer, New Grad · Result: passed R1
Coding
- An array gives each node's parent. Decide whether these links form one valid tree: Validate a Tree From Its Parent Array.
- The candidate's checks: exactly one root; every other node has one parent, so
n - 1edges; every node reachable from the root; no node visited twice, which rules out cycles and extra paths. - They built an adjacency list and counted roots, rejecting anything other than one. Then they traversed from the root with a visited array: a repeat visit meant invalid, and so did any node left unvisited.
- A reader asked whether "no cycle" meant directed or undirected; the candidate did not clarify.
Common questions
How do you check a Google parent-array tree is valid?
Report 01 required exactly one root, then traversed from it, failing on any repeat visit or unvisited node.
Keep practicing
- Validate a Tree From Its Parent Array: the R1 question from report 01.
- Google coding question bank (sign-in needed).
- Google interview guide and Google hiring insights: stages, practice problems and recent hiring signals.
- Experience feed: more interview reports from other companies and roles.
Sources: Anywhere useful interview info can be found.
0 total reactions. Your reactions: none.
0 comments
Comments
0No comments yet — be the first to share what you know.