franz-macbook:~ mdfranz$ ruby moonface.rb
ddddddd
ddddddd
franz-macbook:~ mdfranz$ ruby moonface.rb me
moonface.rb:2:in `gets': No such file or directory - me (Errno::ENOENT)
from moonface.rb:2
mefranz-macbook:~ mdfranz$ cat moonface.rb
print ARGV
moonface = gets
print moonface
What gives? See gets documentation for the answer.
The solution is to use $stdin.gets
No comments:
Post a Comment