In the video, sir used three variables (low,mid,high) in the loop and swapped their values.
I have an other solution if we create three variables (zero,one,two)=0 and then just loop through the array once and increment each one as we encounter 0,1,2 respectively and then change the array,
would that be considered as a o(1) space complexity solution and is it right?