| Strings as Arrays of Characters Not Ideal... | Next Slide |
Representing strings with arrays of characters presents some problems:
ErrorsExample: Because strings are stored in arrays, it is possible to attempt to access locations outside of the memory allotted to the string:char label[10] = "value"; label[-1] = 'a'; // Eeek! label[200] = 'z'; // No such location here! |