I was hoping you would demonstrate the difference yourself using sizeof as was mentioned earlier, but you did not :pQuote:
Does this differ in C++? In C++ are arrays not glorified pointers?
To demonstrate:
To demonstrate:
On my system, the output is "6 4". Basically, C++ has the same distinction between arrays and pointers as C.Code:#include <iostream>
int main() {
char pointer[] = "keira";
char* otherPointer = pointer;
std::cout << sizeof(pointer) << " " << sizeof(otherPointer) << std::endl;
return 0;
}

