Quick Overview

Count connected friend groups from a symmetric adjacency matrix where indirect connections place people in the same group. Work within a 200-person limit, preserve the input, and correctly handle isolated people and multiple disconnected components.

Count Connected Friend Groups

Company: OpenAI

Role: Software Engineer

Category: Coding & Algorithms

Difficulty: medium

Interview Round: Technical Screen

Quick Answer: Count connected friend groups from a symmetric adjacency matrix where indirect connections place people in the same group. Work within a 200-person limit, preserve the input, and correctly handle isolated people and multiple disconnected components.

Loading…