Pergunta de entrevista da empresa Rakuten

They let me do a demo assessment where I had to solve a problem titled missing integer, which was to create a function to return the smallest integer which is not present within an array