I have a program that writes to two numbers to a file, I have another one that is supposed to read those numbers and add them together, how can I add those numbers together in the second file?
You read the file, parse the numbers, add them, and then do whatever you need with the result.
Possibly useful are io/ioutil.ReadFile or bufio.Scanner, and the strconv package.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.