If I can say... why can't I say...

Q

If I can say
char a[] = "Hello, world!";
why can't I say
char a[14];

✍: Guest

A

Strings are arrays, and you can't assign arrays directly. Use strcpy instead: strcpy(a, "Hello, world!");

2016-03-11, 1155👍, 0💬