Uber interview question

basic probability and coding question in the screening