• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

diffrences between Random methods...

 
Josh Tambini
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what are the diffrences between the Random mathod that is in the Math.Random()
to the imported method from java.util.Random
???
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24211
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
java.util.Random has method to let you obtain random integers, doubles, and other data types, and exert a bit of control over how those numbers are generated.

Math.random() is just a simple convenience method that lets you get a series of random doubles. Its implementation uses java.util.Random internally.
 
Josh Tambini
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i see...10x!
the math.random...is more conviniet thouh...(-: its static ..etc...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic