A class is another great way to group together code that serves the same purpose, and is used to specify your own objects, which can then be used to save lots of information and passed around as a single object via a variable.
A good example of this is a “Person.” A person has multiple properties associated with them. For example, a person has a name, age, height, hair color, favorite colors, and shoe size, to name a few. If you need to create an object that has lots of properties, a class is the best way to group this information together.