How to return a value from a void function and use it inside the void loop?

gfvalvo:
Also, personally, I would not name a function that I wrote 'print'. It appears to be a keyword in Arduino. At least the IDE makes it a different color and that makes me nervous.

Whether or not the IDE makes a word orange has nothing to do with its being a keyword or not. It only means that it is listed in a keywords.txt file in some library. The only purpose is to make some words turn orange. It serves no other real purpose. What's worse is that the library only needs to be in your folder to have this effect. It happens even for libraries not included in the current code. If you want the colors of words to actually mean anything, then you have to use a more grown-up IDE like Eclipse.