¼Ò¼³ java.lang ¼Ò½ºÄڵ堠Math  08.. Math.pow  

¿øÀÇ ³ÐÀ̸¦ ±¸ÇÏ´Â ¿¹Á¦

TestPow.java 

public class TestPow {
  
public static void 
main(String args[]) {
    
double circleRadius = 1.0
;
    
double circleArea = Math.PI * Math.pow(circleRadius, 2.0
);

    System.out.println(
"The area of the circle is " 
+ circleArea);
  } 
}

C:\javaExample\Math>javac TestPow.java
C:\javaExample\Math>java TestPow
The area of the circle is 3.141592653589793

MathŬ·¡½ºÀÇ pow()¸¦ ÀÌ¿ëÇØ¼­ ¿øÀÇ ³ÐÀ̸¦ ±¸ÇÒ ¼ö ÀÖ´Ù.



jabookÀúÀÚ¸íÇÔ
Á¦¸ñ:¼Ò¼³°°Àº¹Ì´ÏÄÚµå
ÀÛ¼ºÀÚ:Àںϸâ¹ö ÇÑâÇå