LinkedIn interview question

Very standard/easy programming questions