Re: Ruby Datastructure Data structures is a generalized name for arrays,hashes,string
Data structures have been invented because simple variables are not enough for solving more complex problems.
Methods are give other names too, such as functions,subprograms or procedures, while in other programming languages there might be several differences between all these, they all mean pretty much the same thing in Ruby, although everyone is trying to using the term "method" only.
Here's how you define a method:
def mymethod
puts "this is my first method"
end |