A

Admin • 828.03K Points
Coach

Q. What will be the output of the following code: float f = 3.14;

  • (A) Valid declaration
  • (B) Compile-time error
  • (C) Runtime error
  • (D) Infinite loop

Explanation by: Admin
3.14 is a double by default; should be 3.14f or casted to float.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.