Initialization different from assignment?
问题 1.char str[] = "hello"; //legal 2.char str1[]; str1 = "hello"; // illegal I understand that "hello" returns the address of the string literal from the string literal pool which cannot be directly assigned to an array variable. And in the first case the characters from the "hello" literal are copied one by one into the array with a '\0' added at the end. Is this because the assignment operator "=" is overloaded here to support this? I would also like to know other interesting cases wherein