How do I achieve the dynamic equivalent of this static array initialisation:
char c[2] = {}; // Sets all members to '\0';
In other words, create a dynamic array with all values initialised to the termination character:
char* c = new char[length]; // how do i amend this?
1 Answer