0

can you help me with the code for that using the logic:

1) randomly select the start point

2) predetermine the distance you need that car to travel using nextGaussian()

3) identify all the end points that are that distance away

4) randomly select one

as you can see, i don't know how to do steps 3 and 4

```
for (int i = 0; i < Math.random() * 10; i++) {
int drivingDistance = 0
int mean = 50;
int stddev = 30;
Random r = new Random();
//randomly pick start points
int startX = (int)(Math.random() * gridWidth);
int startY = (int)(Math.random() * gridHeight);
//pick driving distance
drivingDistance = (int)(r.nextGaussian() * stddev + mean);
//find all possible destinations given start point
//randomly pick one
```