Which of the following escape sequences placed at the end of a string makes the string a Null Terminated String?

Which of the following escape sequences placed at the end of a string makes the string a Null Terminated String?
A. ‘\p’
B. ‘\u’
C. ‘\0’
D. ‘\1’
 
Answer: C
Explanation: The ‘\0’ when placed at the end of a string makes it a null terminated string which is simply a single dimensional array of characters that are trailed by the ‘\0’ escape sequence. It is also called the ASCII NUL character.
 

Tìm kiếm

Back
Top