C++ writing and reading doubles from a binary file

前端 未结 4 1146
春和景丽
春和景丽 2021-01-06 04:45

I want to perform disk I/O operations for a program that takes too much RAM. I use matrices of doubles and think writing them to disk as bytes is the fastest way (I need to

4条回答
  •  南方客
    南方客 (楼主)
    2021-01-06 05:12

    I think that the portability issue only occurs when you write to a file and read from it on a different machine. However, since you said you want to read/write to a file because of ram limitations, I can only assume you would do read/write operations on one machine at a time. This should work.

提交回复
热议问题