Aug 1, 2013 at 11:20pm UTC
when used like this:
strcpy(buf + length, tempBuf);
How does the "length" part of this work ? I know that this will join the two string together in buf, but I don't understand how 'length' come in play.
Aug 1, 2013 at 11:41pm UTC
The first line says, "put buf1 at the location of buf." The second line says "put tempBuf at the location (buf + length)." Assuming that buf1 has a length of "length", you know the location of (buf + length) is the end of buf1.
Topic archived. No new replies allowed.
General C++ Programming
© cplusplus.com, 2000-2016 - All rights reserved -
Spotted an error? contact us