Home » C++ Programming » Data Types » Question
  1. Select the right option.
    Given the variables a, b are of char type and c, d, e are of int type
    i. e = (c * d) / (c + d);
    ii. e = (a * b) / (c + d);
    1. i is false and ii is true
    2. i is true but ii is false
    3. both i and ii are false
    4. both i and ii are true
    5. None of these
Correct Option: D

Every character constant has an integer value. Also char belongs to the integral type hence arithmetic and logical operations can be performed on them.



Your comments will be displayed only after manual approval.