Domanda di colloquio di WD

given array that have 3 colored balls ..please sort them in min time

Risposta di colloquio

Anonimo

1 dic 2022

you can use two pointers , one pointer for the start of the array and the other for the end of the array . sort two colors and the last will sorted alone .