3 ms·
Many string functions are intended to operate on a substring. These functions would appear to need the original string passed in every time to find the length.
by projektfu 7y ago
Many string functions are intended to operate on a substring. These functions would appear to need the original string passed in every time to find the length.
- glxxyz 7y agoEvery pointer into an array could pass the triple {current, start, len}, or even maybe the quadruple {current, start, len, allocated}, which is the kind of minimal efficiency C programmers are looking for.