📜  java secureRandom 一定范围 - Java 代码示例

📅  最后修改于: 2022-03-11 14:52:13.954000             🧑  作者: Mango

代码示例1
SecureRandom random = new SecureRandom();

    int max=50;
    int min =1;

    System.out.println(random.nextInt(max-min+1)+min);