Paul Lutus wrote: > Peter Bailey wrote: > > / ... > >> Thanks, Paul. And, I've tried that: >> >> files = ARGV >> files.each do |f| >> f = f.to_s >> f.gsub!(/-/, "..") >> puts f >> end >> >> I get a "can't modify frozen string" error message. > > 1. "f" is already a string, it doesn't need ".to_s". > > 2. I ran your code without error, Ruby 1.8.4. Are you sure you posted > the > same code you are testing? I ran it again, too, and, I still get the "can't modify frozen string (TypeError)" error. On the command line, I typed: test1.rb im123000-im123005, im123007, im123009 with "test1.rb" being the code above. -- Posted via http://www.ruby-forum.com/.