int count_lines (ifstream& thefilename) { char (y); int counter = 0 ; while (!thefilename.eof()) { thefilename.get(y); if (y == '\n'); } counter = counter ++ ; if (y! = '\n'){ counter = counter ++ ; } return 0; }