//import java.util.Scanner;
import java.util.ArrayList;
import java.util.List;
import java.util.Arrays;
//import java.util.Random;

import java.io.RandomAccessFile;
import java.io.File;
import java.io.IOException;
import java.io.FileNotFoundException;

public class PersonTester{


  //retuens a random line(name since there is a name on each line) form a file and retuensd it as a string
  //this method is modified form a stackoverflow post.
  //link to origanal post http://stackoverflow.com/a/19850005
  
  //NOTE only 4080 names can be generated after that the 
  //name fred will be used and filenotfound error wqill be printed
  public static String getRandomName() {
    String name = "Fred";
    try{
      RandomAccessFile f = new RandomAccessFile("namelist", "r");
      long randomLocation = (long) (Math.random() * f.length());
      f.seek(randomLocation);
      f.readLine();
      name = f.readLine();
    
    } catch(FileNotFoundException e) {
      System.out.println("Error: namelist File Not found");
    } catch(IOException e) {
      System.out.println("Error: IO Exeption");
    }
   
    return name;
  }
  public static String getFullName() {
    return getRandomName()+" "+getRandomName();
  }

  public static void main(String[] args) {
    
    ArrayList<Person> people = new ArrayList<Person>();
    people.add(new Person(getFullName()));
    people.get(0).say("");
    System.out.print("In a small town");
    
  }
}

@@ -97,18 +97,16 @@
 Arrays;%0A
-//
 import j
@@ -1360,24 +1360,26 @@
 me()));%0A    
+//
 people.get(0
@@ -1385,24 +1385,233 @@
 0).say(%22%22);%0A
+    %0A    Random rand = new Random();%0A    int population = rand.nextInt(1500) + 501;%0A    for(int i = 0; i %3C population; i++) %7B%0A      people.add(new Person(getFullName()));%0A      people.get(i).sayHello();%0A    %7D%0A
     System.o
@@ -1623,17 +1623,16 @@
 int(%22In 
-a
  small t
@@ -1634,16 +1634,113 @@
 all town
+ called Randville there are %22+population+%22 people living their lives.%5Cn%22);%0A    System.out.print(%22
 %22);%0A    

Update PersonTester.java