I know I could export an array into a table form by
n={{1,3,3},{4,5,6}}
Export["file.txt",n,"Table"]
But how do I write some information before exporting the table to the same file?
I know I could write information by something like:
x=37
stmp = OpenWrite["file.txt"]
WriteString[stmp, "E=", x, "\n"];
Close[stmp]
But putting table into the same file will erase previous information: E=37
Does anyone know how to solve this problem?
You can simply pass the stream name (
stmp) toExport, like this: