Function not printing in the console

Why this function not printing in the console and not showing any error?
2 Replies
Jochem
Jochem17mo ago
why would it print? You're not asking it to print, and computers don't do anything you don't ask them to do to print things in the console, you have to use console.log() with the value you want to print between the brackets:
console.log(favrtFruit());
console.log(favrtFruit());
Rägnar O'ock
Rägnar O'ock17mo ago
Just like Jochem said. I can see why you would ask that as the console automatically prints the return of the last line you put in. But that's only when you run code directly from the console
Want results from more Discord servers?
Add your server