Hi everyone, I was reading a c++ code and I saw this:
#include <cstdlib>
#include <iostream>
using namespace std;
int main(int argc, char *argv[])
{
char cTmp[] = "Hello There";
char *p = cTmp;
for( ;*p; p++ ){
cout << *p;}
cout << "\n\n\n\n";
cin >> cTmp;
return 0;
}
I will appreciate if someone can help me understand how/why this code works.
Thanks
Last edited on