Random extends java.util.Random { public int dice(int num, int sides) { int ret = 0; while(num > 0){ ret += nextInt(sides) + 1; num -= 1; } return ret; } Random();  Random(long arg0); static Random getInstance(); int bestOf(int num, int outof, int sides); int bestOf(int num, List<Integer> group); int bestOf(int num, int outof, String g); T choice(T c0, T... c); T choice(List<T> c); T choice(Collection<T> c); int dice(int num, int sides); List<Integer> diceList(int num, int sides); int guess(String str); int nextInt(int bottom, int top); void shuffle(List<T> list);  }
@Test public void testDice() { int got = r.guess("5d10"); assertEquals(34, got); }