How to create one object which can be accessed by two classes in java code example Example: java create new object Car mycar = new Car();