A

Admin • 833K Points
Coach

Q. What will be the output of the following Java code?
class area {
public static void main(String args[])
{
double r, pi, a;
r = 9.8;
pi = 3.14;
a = pi * r * r;
System.out.println(a);
}
}

  • (A) 301.5656
  • (B) 301
  • (C) 301.56
  • (D) 301.56560000
  • Correct Answer - Option(A)
  • Views: 30
  • Filed under category Java
  • Hashtags:

No solution found for this question.
Add Solution and get +2 points.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.