Non-void function

i need to prompt user by name to enter a favorite number.
im trying to creat a non-void function to send the user's name and obtain and return favorite number as an int.
i need help.
anyone??
Help with what exactly?
int nonVoidFunction(const string& name)
i got the user's name with a non-void function
now i need to come up with another non-void function asking the user to enter a number. in this function it needs to show the user's name obtain and return the favorite number as an int.
Yeah, the prototype of that function is above.
Although I can't see why you would have problems coming up with that yourself if you already did exactly the same for getting the name.
I don't think you fully understand basic functions, research them. The fact that you called it a non-void function and not an int returning function suggests that you've never made a function that didn't return void before
Topic archived. No new replies allowed.