Jump to content

  • Log In with Google      Sign In   
  • Create Account


#Actualifthen

Posted 01 December 2012 - 05:24 PM

SiCrane described your problem. The correct version is
[source lang="cpp"]void wait(int x){ Sleep(1000 * x);}[/source]
By writing "int" in front of your function, you are saying that it will return an integer. But why should you return an integer in a wait function? If you write "void" instead, you are saying that the function does not return anything.
Solve your problems by thinking about them, not by strafing around them.

#3ifthen

Posted 01 December 2012 - 05:23 PM

SiCrane described your problem. The correct version is
[source lang="cpp"]void wait(int x){ Sleep(1000 * x);}[/source]
By writing "int" in front of your function, you are saying that it will return an integer. But why should you return an integer in a wait function? If you write "void" instead, you are saying that the function does not return anything.
Solve your problems by thinking about them, not by strafing around them.

#2ifthen

Posted 01 December 2012 - 05:23 PM

SiCrane described your problem. The correct version is
[source lang="cpp"]void wait(int x){ Sleep(1000 * x);}[/source]
By writing "int" in front of your function, you are saying that it will return an integer. But why should you return an integer in a wait function? If you write "void" instead, you are saying that the function does not return anything.
Solve your problems by thinking about them, not by strafing around them.

#1ifthen

Posted 01 December 2012 - 05:23 PM

SiCrane described your problem. The correct version is
[source lang="cpp"]void wait(int x){ Sleep(1000 * x)}[/source]
By writing "int" in front of your function, you are saying that it will return an integer. But why should you return an integer in a wait function? If you write "void" instead, you are saying that the function does not return anything.
Solve your problems by thinking about them, not by strafing around them.

PARTNERS