def addLinesToCString(cString, lines):
 for line in lines:
  if (line != ''):
   cString.write((line + '\n'))

def addLinesToCString ( cString , lines ) : for line in lines : if ( line != '' ) : cString . write ( ( line + '\n' ) )
add lines which have something to cstringio .