A

Admin • 833.24K Points
Coach

Q. What will this code print?

Code:
#define PI 3.14
int main() {
printf("%f", PI);
return 0;
}
  • (A) 3.14
  • (B) 3
  • (C) Error
  • (D) 0.00
  • Correct Answer - Option(A)
  • Views: 27
  • Filed under category C Programming
  • Hashtags:

Explanation by: Admin

The macro PI is replaced by 3.14 before compilation.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.