Console.log question

Hi! Students are working on a project and would like information from console.log. Can Console.log be used to count clicks of the counter pattern?

I created a couple quick examples to demonstrate the thought…

Linked are similar examples in both app lab and game lab. We would like the console.log to measure how many clicks are being selected at different points in the program.

I know in Gamelab, clicks are visible on screen with text and calls to the variable, but the vision is to have the count reported in cosole.log.
.App Lab Example

Game Lab Example

Thanks!

Do you want it so it counts the clicks for the animals or just clicks anywhere?

Well, if you are talking about showing how many clicks are performed without a variable, that’s kind of impossible if there is no variable.

But if there is a variable, just use console.log() in a loop. Or you could put in each mouse click on the animal.