Java Random Int randInt(int n)

Here you can find the source of randInt(int n)

Description

rand Int

License

Apache License

Declaration

@Deprecated
    public static int randInt(int n) 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.util.Random;

public class Main {
    @Deprecated/*  ww  w. j a v  a  2  s .com*/
    private static Random random = new Random();

    @Deprecated
    public static int randInt(int n) {
        return random.nextInt(n);
    }
}

Related

  1. randInt(int min, int max)
  2. randInt(int min, int max)
  3. randInt(int min, int max)
  4. randInt(int n)
  5. randInt(int n)
  6. randInt(int range)
  7. randInt(int range)
  8. RandInt(int x, int y)
  9. randIntArray(int length)