原です。
どうも read の使い方が分からないのですが、
------^ copy.rb
#!/usr/local/bin/ruby
src, tar = ARGV
print src, "=>", tar, "\n"
s = open(src, "r")
t = open(tar, "w")
#s.each_byte { |i| t.write(i.chr) }
t.write(s.read)
s.close
t.close
------$ copy.rb
を動かすと
copy.rb:7:in `read': Wrong # of arguments(134686548 for 1)
といわれてしまいます。どういうことでしょう?
---===-=-=-=-=-=-=-=-=======--=-=-=-==-=-===-=-=-=-=-=-=--=-==-=--
Shin-ichro Hara(Nagaoka Univ.of Tech.)