Can someone help me how can I multiple lines in file handling c++ ? I want to read the lines that starts from the search up to 3 next line.
ifstream fileInput;
fileInput.open("D:\\devc++\\program\\sample.txt");
string lines, search;
cout << "Enter employee number to search for: ";
cin >> search;
  while(!fileInput.eof()){
      getline(fileInput,lines);
      if(lines.find(search)!=string::npos)
        {
             cout << "Found " << lines << endl;
             cout<<"\n";
        }
 }
 
     
    