The number of bytes occupied when char[ ] is initialized

int main(int argc, char *argv[])  
{  
    char a[] = "12"; //with end character '\0'  
    printf("The number of bytes in a is: %d\n", sizeof(a));  
  
    char b[] = { '1', '2', '3' };  
    printf("The number of bytes in b is: %d\n", sizeof(b));  
  
    system("pause");  
    return 0;  
}  

operation result:

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325559623&siteId=291194637