Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Vehicle{
- private int noOfTyres;
- private Boolean accesories;
- private String brand;
- private int static counter=0;
- private int counterNum;
- public Vehicle(int noOfTyres, int accessories, int brand){
- counter++;
- this.noOfTyres= noOfTyres;
- this.accessories= accessories;
- this.brand= brand;
- counterNum= counter;}
- }
- public class Vehicle{
- private int noOfTyres;
- private Boolean accesories;
- private String brand;
- private int counter=0;
- public Vehicle(int noOfTyres, int accessories, int brand){
- counter++;
- this.counter= counter;
- this.noOfTyres= noOfTyres;
- this.accessories= accessories;
- this.brand= brand;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement