how to write a constructor that can be used to create object variables in java code example Example: create instance object java myCar = new Car();