如何将数组写入文件txt,以及如何将输出的文保存在自己写的mathematica文件的,同一个文件夹下面,比如nb 包装在桌面上,结果也输出到桌面上,谢谢fname = FileNameJoin[{"P.txt"}];s = OpenWrite[fname]Write[s, #] & /@ Array[result, {3, 100}, 0] Close[s]