I am working over one problem where I need to store some calculated data in CPP (map data) for future reference so that it can later be used by directly loading it into memory. (Somewhat similar to pickle in python) What will be the fastest way to achieve this.
我正在解决一个问题,我需要将一些计算数据存储在CPP(地图数据)*将来参考,以便以后可以直接将其加载到内存中使用。 (有点类似于python中的pickle)实现这一目标的最快方法是什么。
1 个解决方案
#1
0
Compile your program with
用你的程序编译你的程序
g++ -o output.o program.cpp
[Considering program.cpp
is in the current working directory]
[考虑program.cpp在当前工作目录中]
Then, while executing
然后,在执行时
./output.o > output.txt
This would store your output from program.cpp
in output.txt
for future reference.
这会将program.cpp的输出存储在output.txt中以供将来参考。
#1
0
Compile your program with
用你的程序编译你的程序
g++ -o output.o program.cpp
[Considering program.cpp
is in the current working directory]
[考虑program.cpp在当前工作目录中]
Then, while executing
然后,在执行时
./output.o > output.txt
This would store your output from program.cpp
in output.txt
for future reference.
这会将program.cpp的输出存储在output.txt中以供将来参考。