Java vs Python via the lens of an interview problem