CP DML Q9

0. Consider following program fragment

if (a > b)
printf("a> b") ;
else
printf ("else part") ;
print f("a< = b") a <= b

will be printed if

  • Option : D
  • Explanation : The else clause has no brackets i.e., {and}. This means the else clause is made up only one statement. So, printf ("a b a< = b. Hence the answer
Cancel reply

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


Cancel reply

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