Pergunta de entrevista da empresa J.P. Morgan

Basic coding questions, then your thought process on them