posted on February 12, 2010 by admin How to Initialize Character Array Elements to ‘\0′ in C++ Filed under C_C++ Method 1: #define MAX_PATH 100 .. char arr[ MAX_PATH ] = { 0 } ; Method 2: .. char arr[ MAX_PATH ] ; memset ( arr, 0, MAX_PATH ); Both the above methods would initialize all the array elements to ‘