0

I'm still fairly new to C, so I was wondering what would be the fastest way to get a char pointer pointing and ending between 2 different char delimiters?

For example:
text text (text I need)

I need a char * to "text I need"

2
Contributors
1
Reply
2
Views
8 Years
Discussion Span
Last Post by William Hemsworth
0

Loop through the characters until you find your first delimiter, save the index of that character, loop through the characters from the first index, and when you find the second delimiter, save the index of that too. Then pull out the characters between the two indicies.

Edited by William Hemsworth: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.