Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

1
  • 1
    All other answers focused on the "point to string literal address vs. copy string's chars into array", which is valid but is specific to the OP's example code. All failed to mention this (the different result of sizeof()), which is -in my opinion- a very important difference between arrays and pointers. Commented Dec 14, 2014 at 14:24