package oop2.Mathh;
public class MathA {
public static void main(String[] args) {
System.out.println(Math.PI);
System.out.println(Math.E);
System.out.println(Math.round(3.156)); //四舍五入
System.out.println(Math.ceil(3.16)); //向上取整
System.out.println(Math.floor(3.9)); //向下取整
System.out.println(Math.random()); //产生随机数[0 , 1)
System.out.println(Math.sqrt(64)); //开平方
System.out.println(Math.pow(2,3)); // 2的3次幂
System.out.println(Math.abs(-5)); // 去绝对值
System.out.println(Math.max(2,9)); //比较两个数的大小
System.out.println(Math.min(3,2));
}
}