Reputation: 1
This is from exercise 39 from Learn Ruby The Hardway
I am currently getting this error.
/usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': /home/lost/Dropbox/Ruby/Dict.rb:45: formal argument cannot be a constant (SyntaxError)
def Dict.set(aDict, Key, value)
^
from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require
from ex39_test.rb:1:in `<main>'
You can find my code here
Any help is greatly appreciated.
Upvotes: 0
Views: 58
Reputation: 6834
I think the problem is with your arguments in Dict
module.
def Dict.set(aDict, Key, value)
should be:
def Dict.set(aDict, key, value)
Upvotes: 2