Pergunta de entrevista da empresa Freshworks

Given a linked list, return true if there is a loop in it