TATA ELXSI interview question

Very basic electronics and coding questions.