RFS: Classes and Objects - 008
Classes and Objects are the basis of most of the work we'll be doing in Ruby. Let's create our own custom class in this episode.
Defining a Class
This is the simplest class we can create in ruby, it does nothing for now.
Creating an Instance
Let's create an instance of this class.
product = Product.new
We now have an instance of the Product class. We can create more instances of this class. But it get's pretty boring since it does nothing. Let's explore what else we can do in the next episode.