Pergunta de entrevista da empresa LinkedIn

Implement a function to determine if a DOM element is the descendant of another one or not.