A
Ari Brown
Hi all,
This is my first post here, so don't dish out the loser points to me
so heartily.
I have only recently gotten into Ruby, and I was writing my own
methods that I might use in a couple future programs (they were YAML
things, like open and closing a file, and reading a file). I saved it
as yaml.rb . However, when I require it ( require 'yaml.rb') and then
try to call a method I had defined in yaml.rb, I get an error saying
that the method had not been defined yet:
test.rb:8: undefined method `yaml_save' for main:Object (NoMethodError)
yaml_save was the method I had tried to use.
Any thoughts? Suggestions? Flames?
Part II
The missing command
Today I was in the car and was coding on my dad's laptop (Windows
XP), and I was writing a shuffling algorithm. I had used the .pop
command in it once, and it worked. But then all of a sudden Ruby was
saying that there was no command 'pop'. The syntax I had used it in
was like so:
b = some_array.pop
Once again, any thoughts? Suggestions? Flames?
--------------------------------------------|
If you're not living on the edge,
then you're just wasting space.
This is my first post here, so don't dish out the loser points to me
so heartily.
I have only recently gotten into Ruby, and I was writing my own
methods that I might use in a couple future programs (they were YAML
things, like open and closing a file, and reading a file). I saved it
as yaml.rb . However, when I require it ( require 'yaml.rb') and then
try to call a method I had defined in yaml.rb, I get an error saying
that the method had not been defined yet:
test.rb:8: undefined method `yaml_save' for main:Object (NoMethodError)
yaml_save was the method I had tried to use.
Any thoughts? Suggestions? Flames?
Part II
The missing command
Today I was in the car and was coding on my dad's laptop (Windows
XP), and I was writing a shuffling algorithm. I had used the .pop
command in it once, and it worked. But then all of a sudden Ruby was
saying that there was no command 'pop'. The syntax I had used it in
was like so:
b = some_array.pop
Once again, any thoughts? Suggestions? Flames?
--------------------------------------------|
If you're not living on the edge,
then you're just wasting space.