- Now that we have cars, lets race
car thejsCar = null; car batmansCar = null; void setup(){ size(500,600); //lets construct a new maruthi car for me thejsCar = new car("Maruthi", "KA51", 10,10); //in the mean time @ batmans cave batmansCar = new car("BatMobile","1",10,200); } void draw(){ background(255); //let me start driving it thejsCar.drive(10); //let me display the car on screen thejsCar.display(); //batman is faster than me batmansCar.drive(30); //let me display batmans car on screen batmansCar.display(); }