in reply to what regular expression do I need?
/[^IMO]/ [download]
Also, don't forget to "chomp" your lines, otherwise all lines will match...