i need to filter duplicate lines from a text. it should store input lines in a vector and call a function to filter. sorry i am obviously a beginner and struggling mightily.
vector <string>
using namespace;
int main(){
bool filter(vector<string> lines, string)
for (int i=0, i<lines.length, ++i){
if (string!=lines){
As for the function filter(), it needs to return a true or false value indicating whether or not the value was found in the vector. Based upon that result, the string should be inserted or not into the vector.