Count the number of cats

  • 3
  • Locked
Write a code that correctly counts the number of created cats (count) and correctly displays the count on the screen.
You can't complete this task, because you're not signed in.
Comments (1)
  • Popular
  • New
  • Old
You must be signed in to leave a comment
2 September, 12:48
More of an intermediate lesson, but the core of the lesson is this: * If a method is declared with the keyword "static", then you must use "Classname.variableName" to access a class variable. * If a method is NOT declared with the keyword "static", then you can use "this.variableName" to access a class variable. I hope this helps anyone attempting this problem.