// 生成0-100之间的随机数,包括0,不包括100。 import java.util.Random; Random random = new Random(); int i = random.nextInt(100);