Qualtrics Interview Question

Asked medium let code question. trapping water in rain.