Pergunta de entrevista da empresa Apple

Reverse the bits of an 32 bit integer Longest substring in a string.