From: iMelody Ooo Date: 2010-09-19T00:01:15+09:00 Subject: Re: Ruby regexpresion, error? :-( Dear Brian Candler, thank you very much, but still have problem. I read a line from file,want to macth ";" f = File.open(filename) f.each do|line| puts line puts line.match( %r{;$}) puts line.match( %r{;\z}) puts line.match( %r{(.*);$}) puts line.match( %r{(.*);\Z}) end result: ABC DEF=""; nil nil nil nil -- Posted via http://www.ruby-forum.com/.