Turing interview question

Both tasks where easy-medium lvl tasks.