Hi,
I have a txt file with some data that looks like this:
a:1(2,3) 55(33,45,67)
b:2(1,33,456) 4(123,12444)
which means that word "a" appear in text 1 in places 2 and 3 and in text 55 in places 33,45 and 67..
I have some texts and I go all over those texts and if I see that the word "a" appears in a text then I need to update the text file above accordingly. (the data about "a" can be bigger than a line of course)
How can I update the line where "a" is without damaging the line where "b" is? I saw here in stackoverflow that I can use maybe xml file. If I use xml file can I read the whole "a" data, update it and then write it again without damaging the "b" line? Or maybe each data about a word can be in some data structure that I can somehow read from the file, update it and then write it to the same position?
Thanks in advance,
Greg