You are currently viewing a snapshot of www.mozilla.org taken on April 21, 2008. Most of this content is
highly out of date (some pages haven't been updated since the project began in 1998) and exists for historical purposes only. If
there are any pages on this archive site that you think should be added back to www.mozilla.org, please file a bug.
Skip to main content
A string isn't...
- A string isn't a bunch of characters in a row in memory. In memory, the characters might be widely separated (suppose one had to download the sequence into multiple buffers).
- A string isn't necessarily a sequence of known length. Often one knows the length, true; but when getting input from, say, a scanner, one might not know the length until after seeing the entire sequence.
- A string need not be a sequence of uniform-sized characters. What does this say about finding the location of a character within a string?
- A string isn't a pointer. And I can't think of any reason why you would think it is. Contrast comparisons between pointers with comparisons between strings.
- A string doesn't necessarily end with a null terminator.
[Previous] [Next]