Find shortest relationship path using BFS

Read the full interview experience this question came from →

Quick Overview

This question evaluates proficiency in graph representations and traversal algorithms—specifically BFS and adjacency-structure construction—for computing unweighted shortest paths and reasoning about reachability.

Find shortest relationship path using BFS

Company: Google

Role: Software Engineer

Category: Coding & Algorithms

Difficulty: medium

Interview Round: Technical Screen

Overview: This question evaluates proficiency in graph representations and traversal algorithms—specifically BFS and adjacency-structure construction—for computing unweighted shortest paths and reasoning about reachability.

Read the full Google Software Engineer interview experience this question came from

Google logo
Google
Feb 12, 2026
mediumSoftware EngineerTechnical ScreenCoding & Algorithms
30
0
Loading...