Here you can find the source of randomFloatInInterval(float lower, float upper)
public static float randomFloatInInterval(float lower, float upper)
//package com.java2s; public class Main { public static float randomFloatInInterval(float lower, float upper) { return (float) (Math.random() * (Math.abs(upper - lower)) + lower); }/*from ww w . j ava 2s. co m*/ }