package cn
.itcast
.p1
.otherapi
;
import java
.util
.Random
;
public class MathDemo
{
public static void
main(String
[] args
) {
double d1
= Math
.ceil(12.56);
double d2
= Math
.floor(12.56);
double d3
= Math
.round(12.46);
Random r
= new Random();
for (int i
= 0; i
< 10; i
++) {
int d
= r
.nextInt(6)+1;
System
.out
.println(d
);
}
}
public static void
sop(String
string) {
System
.out
.println(string);
}
}
转载请注明原文地址:https://blackberry.8miu.com/read-18503.html