MCPcopy Create free account
hub / github.com/VolmitSoftware/Adapt / irand

Method irand

src/main/java/com/volmit/adapt/util/M.java:183–185  ·  view source on GitHub ↗

Get a random int from to (inclusive) @param f the from @param t the to @return the value

(int f, int t)

Source from the content-addressed store, hash-verified

181 * @return the value
182 */
183 public static int irand(int f, int t) {
184 return f + (int) (Math.random() * ((t - f) + 1));
185 }
186
187 /**
188 * Get a random float from to (inclusive)

Callers 1

onMethod · 0.95

Calls 1

randomMethod · 0.80

Tested by

no test coverage detected