Pregunta de entrevista de Tata Technologies

If else coding question and a numbers question