c++ program for reading an unknown size csv file (filled only with floats) with constant (but unknown) number of columns into an array

后端 未结 4 1830
别那么骄傲
别那么骄傲 2021-01-16 09:24

was wondering if someone could give me a hand im trying to build a program that reads in a big data block of floats with unknown size from a csv file. I already wrote this i

4条回答
  •  不思量自难忘°
    2021-01-16 10:09

    As proposed here changing getline escape may help you with better reading of csv file but you need to change type from string to int.

    For dealing with any number of rows and cols you may use multi dimensional vector (vector inside vector as described here), then you have each row in one vector and all rows in the bigger vectors

提交回复
热议问题