Implemented AlgorithmX.pick_row