Google interview question

2 Easy-Medium LC questions each