// setup random generator with system-clock time.var rand1 = new Random();// setup random generator with fixed seed.var rand2 = new Random(123456789);var r = rand1.next(); // exactly the kind of number you get from Math.random()