> Hi All, > > I'm looking for a regex (or other solution, as long as it's quick!) > that > could be used to strip out lines made up entirely of whitespace. > > eg: > > 'x\n \t \n\ny' -> 'x\ny' > > Does anyone have one handy? > > cheers, > > Chris for line in lines: if not line.strip(): continue doStuff(line) cheers, Drea