The declaration
char temp[3] = "";
is same as
char temp[3] = {0};
// `` ascii value is 0
remember remaining elements of half initialized array initialized with 0
.
Point :char temp[3] = ""
is easy to type(means writing), so its preferable.
Look even compare it with this declaration char temp[3] = {''};
(it need more chars to type) Whereas in char temp[3] = "";
is simple (even no type mismatch - int/char).
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…