实例 Java Math.random()

x
 
public class Main {
  public static void main(String[] args) {
    System.out.println(Math.random());  
  }
}
                    

输出结果

0.1573546753722137