def getwords(line):
 line = line.replace(' DCTB ', ' ').strip()
 return [w for w in line.split(' ') if w]

def getwords ( line ) : line = line . replace ( ' DCTB ' , ' ' ) . strip ( ) return [ w for w in line . split ( ' ' ) if w ]
get words on a line .