Java Random Int random(int length)

Here you can find the source of random(int length)

Description

random

License

LGPL

Declaration

public static String random(int length) 

Method Source Code

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

public class Main {

    public static String random(int length) {
        if (length > 16)
            length = 16;/*from   ww w.  j av  a2s .co m*/
        String str = Math.random() + "";
        return str.substring(str.length() - length);
    }
}

Related

  1. randIntArray(int length)
  2. randIntArray(int length)
  3. randIntv(double fr, double to)
  4. randLocation(int min, int max)
  5. Random(int a, boolean Zero)
  6. random(int length)
  7. random(int length, String data)
  8. random(int limit)
  9. random(int lo, int hi)