Home >Backend Development >C++ >What is the True Type of a String Literal in C ?
Determining the Type of a String Literal
Many programmers grapple with understanding the type of a string literal. Is it a const char * (pointer to a constant character) or a const char (constant character)?
The answer lies in the representation of string literals in C . Unlike in C, where string literals are stored as arrays of characters with a null-terminator ('
The above is the detailed content of What is the True Type of a String Literal in C ?. For more information, please follow other related articles on the PHP Chinese website!