Pregunta de entrevista de Google

Leet code type questions, medium diff