1#include<fstream>
2#include<vector>
3using namespace std;
4int main()
5{
6 ifstream file;
7 string inputString;
8 vector<string> data;
9 file.open("/path/to/file");
10 while(file>>inputString) //reads one string at a time
11 data.push_back(inputString); //add it to data vector
12 file.close();
13}