There are two basic approaches for managing NULLnull-terminated byte strings in C programs. The : the first is the static approach, where strings are maintained to maintain strings in statically allocated arrays. The ; the second approach is the dynamic approach, where memory is allocated is to dynamically allocate memory as required. Each approach has advantages and disadvantages. However, it generally makes sense to select a single approach to managing strings and apply it consistently across a project. Otherwise, the decision is left to individual programmers who are likely to make different, inconsistent choices.
...