S&P Global interview question

Basic Java and Android questions