var args stuff
This commit is contained in:
parent
e53ad11e51
commit
fab47f9adf
17
varargs.rb
Normal file
17
varargs.rb
Normal file
@ -0,0 +1,17 @@
|
||||
def shabang(*words)
|
||||
words.each do |word|
|
||||
puts word + ' shabanngggg'
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def main()
|
||||
puts 'what ye have to say?'
|
||||
words = gets().chomp()
|
||||
shabang(*words.split())
|
||||
end
|
||||
|
||||
|
||||
if __FILE__ == $0
|
||||
main()
|
||||
end
|
Loading…
Reference in New Issue
Block a user