← Goldman Sachs questions

Count matrix connections

Filed under Goldman Sachs

Given an M x N matrix of 0s and 1s, count the total number of connections between pairs of cells where both cells have a value of 1. Connections typically refer to adjacent (horizontally or…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Goldman Sachs questions

Collected from public candidate posts and coding forums. Updated Nov 2026.