1 Nov
2010
1 Nov
'10
10:40 p.m.
2010/11/1 Rao, Anant
Hi, I have a ‘char *’. I need to be able to traverse thru the string in both fwd and reverse directions. Say, I have a string ‘world’. I will start with a fwd iter pointing at ‘w’ and start traversing. When I reach the letter ‘r’, I might need to start traversing in the backward direction i.e., the next char should be ‘o’ and I might again need to traverse fwd.
How will You be traversing? Won't operators ++ and -- on a plain iterator/char* suffice? Regards Kris