Pregunta de entrevista de DXC Technology

A leetcode easy question on two pointers.