public SimRace() {
		cars = new Car[numberOfCars];
		accident = new Accident(500, cars);

		for (int i = 0; i < numberOfCars; i++) {
			cars[i] = new Car(laps);
		}
		
		for (Car c : cars) {
			c.start();
		}
		accident.run();
		try {
			for (int i = 0; i < cars.length; i++)
				cars[i].join();
			accident.join();
		} catch (InterruptedException e) {
		}
		
		for(int i = 1; i <= cars.length; i++){
			System.out.println("Car " + i + ": " + cars[i-1].totalTime + "ms, crashed: " + cars[i-1].crashed);
		}
		System.out.println("Crash occurred at: " + accident.crashOccuredAt + "ms");
		

	}