How to write data to a specific cell in a csv file in C++? [duplicate]

  c++

Is there any function in C++ by which you can change the value in a cell?
Suppose this is all the data in a csv file:

1,Apple,red
2,Orange,blue
3,Grapes,green
3,Banana,yellow

How do I change the value in row 2 column 3 to orange?
I could read all the data inside the file, parse it, make changes and write the entire thing back on to the file but that would take a long time if this was a big file.

So is there any way to just find the cell and change the data, by like looping through rows until you reach the specific row, then the column, and changing the data in that spot?

Source: Windows Questions C++

LEAVE A COMMENT