Amazon interview question

Few math questions that are always changing