CS 3304: Comparative Languages
Data Types
[
Course Documents
] : [
Data Types
]
Previous
Contents
Next
Keyword Index
String Length Options
Fixed (static) length (fixed size determined at allocation)
FORTRAN 77, Ada, COBOL
A FORTRAN 90 example:
CHARACTER (LEN = 15) NAME;
Limited dynamic length (fixed maximum size at allocation, but actual contents may be less)
C and C++ char arrays: actual length is indicated by a null character
Dynamic length (may grow and shrink after allocation)
SNOBOL4, Perl