This section focuses on C interview questions, tricky questions, and puzzles, and viva questions based on “if statement”. One shall practice these questions and puzzles to improve their C programming skills needed for various interviews (campus interviews, walk-in interviews, viva exams and company interviews), placements, entrance exams and other competitive exams. These programming questions can be attempted by anyone focusing on learning C Programming language. They can be a beginner, fresher, engineering graduate, engineering student, bca student, mca student, mcs students or an experienced IT professional. It will improve their understanding of C Language. Here is a listing of C questions and puzzles on “if statement” along with answers and/or explanations.

Correct Answer : 2Explanation : in if the value of i is updated to 2, then printf() prints the value of i so the value of i is printed 2.
Note: using a ; after if denotes that the statement after if are not controlled by this if statement.