Spinny | OA | 25thfeb 2026 | Binary Signals Sorting Sweep

Question · Posted Apr 2026

Question 1: Binary Signals Sorting Sweeps Problem Statement: You have an array of n binary signals, where each signal initially has a value of 0. There are n different pings made to these signals, changing their value from 0 to 1. The ith ping affects the signal at index ping[i]. After each ping, the processor sorts the array by performing sweeps from left to right, swapping adjacent elements where signal[i] = 1 and signal[i+1] = 0. The processor stops when ...

The full answer & interview discussion are available to premium members.

Log in Create a free account