From: Hans Mackowiak Date: 2012-12-22T15:54:02+09:00 Subject: Re: Perl to Ruby: regex captures to assignment. dbuckhal what about this? w,n,d = 1,frac,0 unless %r{(?:(?[-]?\d+)\s*)??(?[-]?\d+)/(?\d+)}xms =~ frac w,n,d = w.to_i,n.to_i,d.to_i with that you do not need the $vars -- Posted via http://www.ruby-forum.com/.