A

Admin • 831.35K Points
Coach

Q. Which of the following is the correct way to declare a float variable?

  • (A) float f = 5.0;
  • (B) float f = '5.0';
  • (C) float f = 5.0f;
  • (D) float f = "5.0";

Explanation by: Admin
Use 'f' or 'F' suffix to indicate a float literal.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.