compile and run time

Hi, can someone make me clear what exactly happens at compile time and run time? For e.g.. when we say
cout<< "enter a variable";
cin>>var;
what happens at compile time and what happens at run time? does the variable that the user enters is taken at runtime?

I am asking this because they say command line arguments are executed at runtime and are thus faster.

I first want to make it clear what it means by compile time and runtime if anyone can explain it with the scenario mentioned above.
Thanks in advance

Compile time means at the time when the program is being compiled, i.e. when the executable (or object) file is created by the compiler.

Run time means at the time when the program is running.

The value is read from the user when you run the program (not when you create the program) so that means it happens at run time.
Topic archived. No new replies allowed.