Re: compressing consecutive spaces

2007-07-09 Thread [EMAIL PROTECTED]
On Jul 9, 7:38 am, Beliavsky <[EMAIL PROTECTED]> wrote: > How can I replace multiple consecutive spaces in a file with a single > character (usually a space, but maybe a comma if converting to a CSV > file)? Ideally, the Python program would not compress consecutive > spaces inside single or double

Re: compressing consecutive spaces

2007-07-09 Thread Paul McGuire
On Jul 9, 9:38 am, Beliavsky <[EMAIL PROTECTED]> wrote: > How can I replace multiple consecutive spaces in a file with a single > character (usually a space, but maybe a comma if converting to a CSV > file)? Ideally, the Python program would not compress consecutive > spaces inside single or double

Re: compressing consecutive spaces

2007-07-09 Thread Pomato
On Jul 9, 7:38 am, Beliavsky <[EMAIL PROTECTED]> wrote: > How can I replace multiple consecutive spaces in a file with a single > character (usually a space, but maybe a comma if converting to a CSV > file)? Ideally, the Python program would not compress consecutive > spaces inside single or double

compressing consecutive spaces

2007-07-09 Thread Beliavsky
How can I replace multiple consecutive spaces in a file with a single character (usually a space, but maybe a comma if converting to a CSV file)? Ideally, the Python program would not compress consecutive spaces inside single or double quotes. An inelegant method is to repeatedly replace two consec