ok so here the problem the code works just adds break on to every line i want it to only add breaks to the line that don't alraedy have spaces after them.

while (! fileIn.eof() )
   {

    getline (fileIn, linea);
    fileOut << linea << b <<endl;




   }//end while

is what im working with right now.

you can write function witch trims spaces from lines ends or you can use isspace() function to indetify spaces, you ll find it in cctype header file

ok so here the problem the code works just adds break on to every line i want it to only add breaks to the line that don't alraedy have spaces after them.

OK so you say you have a problem then you say the code works and it just does something about break but you don't say what break means and what spaces have to do with anything the code you posted without code tags by the way you need to use them doesn't do anything with spaces nor breaks so we don't have any idea what you are really doing you might want to explain in detail what you are trying to do also explain what the code does wrong be explicit and also write in real english you know sentences punctuation and so on so we can understand what you are writing