|
||||||
| Java Help Java Help forum discussing all Java platforms - J2ME, J2SE and J2EE - as well as relevant standards, APIs and frameworks such as Swing, Servlets, JSPs, Applets, Struts, Spring, Hibernate, ANT, EJB, and other Java-related topics. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
Hi,
I'm new to programming and am using BlueJ. I'm trying to generate n random points with [x,y] co-ords each in the range (0,1). double[] location = new double [n]; for (i=0;i<n;i++){ location[i]=Math.random(); is what i was thinking however this does not work since i is not defined properly. I'm a little confused, any help would be appreciated. Thanks |
| Sponsored Links |
|
|
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Generating Random Numbers with PHP | Paradine | PHP Tutorials | 4 | 08-27-2007 07:09 PM |
| Return random numbers without duplicates | Paradine | PHP Tutorials | 0 | 08-26-2007 02:07 PM |
| Code:PHP Random Functions | John | PHP Tutorials | 2 | 12-03-2006 10:04 AM |
| Store and Points System | Jordan | Announcements | 9 | 08-28-2006 01:38 PM |
| I need to generate a random number in PHP | dirkfirst | PHP Forum | 7 | 07-05-2006 09:58 PM |
| Xav | ........ | 1333.07 |
| MeTh0Dz|Reb0rn | ........ | 1055.7 |
| John | ........ | 883.37 |
| morefood2001 | ........ | 879.43 |
| marwex89 | ........ | 869.98 |
| WingedPanther | ........ | 851.68 |
| Brandon W | ........ | 760.23 |
| chili5 | ........ | 312.39 |
| Steve.L | ........ | 247.05 |
| dcs | ........ | 219.87 |
Goal: 100,000 Posts
Complete: 82%