nextFloat method

double nextFloat (double min, [ double max ])

Generates a float in the range 'min', 'max'. If 'max' is omitted, then the range will be set to 0, 'min'.

  • min minimum value of the float that will be generated. If 'max' is omitted, then 'max' is set to 'min' and 'min' is set to 0.
  • max (optional) maximum value of the float that will be generated. Defaults to 'min' if omitted. Returns generated random float value.