Home » C Programming » Variables » Question
  1. Which of the following operations are INCORRECT ?
    1. int a = 15; a = a%5;
    2. short int b = 53; b = b%15;
    3. long int c = 125L; c = c % 14;
    4. float d = 6.128; d = d%7;
Correct Option: D

The modulus (%) operator can only be used on integer types.



Your comments will be displayed only after manual approval.