sorry, my bad, ive just looked over the code again, it doesnt return the integer, the cout is performed on the simon function the goes back to the main fuction. correct? sorry
Type: Posts; User: brucey2343
sorry, my bad, ive just looked over the code again, it doesnt return the integer, the cout is performed on the simon function the goes back to the main fuction. correct? sorry
beacuse the void simon function is returning the integer value n to the main function?
im completely lost now. the way my inexperienced eyes see it, main() calls void simon(int n) to perform a calculation, simon performs the calculation using n as the value to RETURN to the main...
ok, im gonna get annoying now, but isnt (int n) n a return value???
Why thank you :) but then doesnt the void simon function return to the main() function when its finished the cout command?
i dont understand.... what is return then? I would assume it means to return something to the calling function? I read that main is technically called by the OS, and it returns 0 at the end of main...
Haha, thanks very much, that really helped :) but i do have one more question.
You said that void functions (is that right?) can not, must not and will not return anything. If you draw your...
absence of type, meaning no return should be made.
floating-point number, capable of integer, fractional and exponential values
accurate as "float", but on x86 systems is always at least...
Thanks reaper :) but as i said, total beginner and everything you jost posted was like speaking french to me :( Im starting to wonder if i should just give up? I dont seem to be getting any of the...
// ourfunc1.cpp -- repositioning the using directive
#include <iostream>
using namespace std; // affects all function definitions in this file
void simon(int);
int main()
I'm currently reading C++ Primer 6th Ed, and have just finished chapter 2.
I understand that programming is all about doing things in order, and how cout and cin work. BUT...
im having serious...