How to read lines of text from file and put them into an array

Try specifying the last argument as ‘\n’ in both getline() functions:

getline(myfile, line1[a], '\n');

instead of

getline(myfile, line1[a], ' ');

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)