From: "Kevin E." Date: 2011-10-10T07:44:15+09:00 Subject: Basic OO Class question Hi All I am try to get up to speed on several things at once; namely, OO and also Ruby. I have written a bunch or Ruby scripts to perform various text processing tasks but I think I want to start learning something about OO Programming. I do have the book "Programming Ruby" and it is a great help. My question is related to writing a class for something like a polygon. It can be described by a few integer and string properties. So I could do something like this snippet: class Zone attr_accessor :type, :length def initialize(type, length) @type = type @length = length end end testZ = Zone.new("Rad", 20.1) Here is what I don't know how to do. How do I add an array of integers to this class? It would need to be of variable length. Sorry for the basic question? Kev -- Posted via http://www.ruby-forum.com/.