![oo email parser github oo email parser github](https://stringfixer.com/files/297158185.jpg)
We'll code our Dance module inside the lib/dance_module.rb file. Follow along with the walk-through below to get your code working. Fork and clone this repo by clicking the Github link at the top of the page. Code Along I: Including Module Methods as Instance Methods In this exercise, we'll be defining a Dance module and making it available to both the Dancer and Kid class. Modules allow us to collect and bundle a group of methods and make those methods available to any number of classes. Instead, Kid and Dancer simply need to share some functionality, without being related in any other meaningful way.
![oo email parser github oo email parser github](https://raw.githubusercontent.com/SpamScope/spamscope/develop/docs/logo/spamscope.png)
This situation is not hierarchical, like our Car and Vehicle example. So, we might write a Kid class in which an instance of that class, our little girl who has gone to see the ballet, should have access to all those ballet moves (her performance skill notwithstanding). Similarly, we could imagine a little girl going to see the Nutcracker ballet one Christmas, coming home and wanting to practice all of the ballet moves from the show. We could easily envision writing an app that models the environment of a dance performance. Let's think about a slightly different type of example, one that is less hierarchical. For example, a car is a type of vehicle, so it makes sense for the Car class to inherit from the Vehicle class. The subclass can be understood as a child or subordinate of the super class. Inheriting one class from another makes sense. We learned that through subclasses, a certain class under a super class, the subclass has access to all of the methods of its parent. In the previous lesson, we discussed the concept of inheritance. Learn about modules - another way to lend functionality across classes.