Should Interviewers for Entry Level Programming Positions be “Trained” in Interviewing?

I know that I am going to raise the hackles of quite of few professionals in the IT industry. Would it help, if at the outset, I affirm that what I state here is without malice? I hope so…

Some months ago, one of my students told me that in an interview at a large company in Bangalore, the interviewer asked him to write the smallest C program that is possible. This student is quite intelligent and competent. Baffled as he was, after a few moments, he wrote the following program.

void main(void) {


The interviewer apparently did not think that was the appropriate answer. And after a couple of questions about the college in which he studied, the interviewer terminated the interview. The student did not get selected for a job. He still thinks that he was rejected because of this particular question & answer. The student may be wrong, and the interviewer would possibly have other reasons for not selecting him. I told this student so, and gave him a few words of encouragement.

The student then asked me how this answer could be wrong. This is a complete C program. It compiles correctly. It executes correctly, even though it does not do anything useful. Has he missed something to make this program even smaller? I had to confess that this program could be the smallest, but absolutely useless C program that I have encountered. But I have no clue what the interviewer had in mind when he declared the answer incorrect. Nor do I have any clue why such a question had to be posed at all in an interview? If you have any clue, please do share your thoughts here…

I was present in this interview as one of three interviewers. One of the interviewers asked the student to write a C program that prints itself. Now that is a valid question in that it has a solution.  It is extremely difficult for a student to answer it correctly within the few minutes usually available in an interview. Take a look at one solution.




  char *val1 = “main(){char *val1 = %c%s%c; int val2 = ‘%c’; printf(val1,val2,val1,val2,val2);}”;

  int val2 = ‘”‘;



At first sight it is unlikely to make sense. For many it is unlikely to make sense at the second sight, the third sight, etc. You can compile and execute this program. You will find that this program displays itself. Pretty awesome, isn’t it? I will write about such types of problems one of these days! But is it the type of question one must pose a student in an interview? Perhaps the interviewer wasn’t really looking for a solution, but wanted to hear the approach of the interviewee! I still remember the baffled look on the face of the student, then. Roughly 15 years have passed since this incident. I wish I could communicate with the student and find out how he recollects this episode!

Looks like a section of the interviewers need to be trained on developing interviewing skills.  Several companies in the USA do train their potential interviewers.  Some do in India too. What is required is a cognizance that untrained, egotistic and over-enthusiastic interviewers can damage the psyche of youngsters!

This entry was posted in Motivational by Dr. KRV Subramanian. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *