When you return a value from a function, it can be used in subsequent parts of the program (assigned to a variable, passed to another function as in the test, etc.). Printing doesn't do that - the value is simply written to the console.
That is to say the console is external to your program, not part of it.
That is to say the console is external to your program, not part of it.