DRW interview question

probability question and number theory proofs