package com.codegym.task.task04.task0404;
/*
Cat register
*/
public class Cat {
private static int catCount = 0;
public void addNewCat(int catCount) {
this.catCount = catCount;
}
public static void main(String[] args) {
Cat cat = new Cat();
cat.addNewCat(1);
System.out.println(cat.catCount);
}
}
package com.codegym.task.task04.task0404;
/*
Cat register
*/
public class Cat {
private static int catCount = 0;
public void addNewCat(int catCount) {
//write your code here
this.catCount = catCount;
}
public static void main(String[] args) {
Cat cat = new Cat();
cat.addNewCat(1);
System.out.println(cat.catCount);
}
}