Runtime in last two cases

I am getting runtime in the last two cases. please help

hey @mukuljoshi2711
sorry im not aware with python ,i ll mark this doubt for mentor attention