NTT DATA Interview Question

simple programs and logic. followed by debugging