Pergunta de entrevista da empresa Meta

Basic LC questions at medium difficulty.