1 00:00:00,231 --> 00:00:04,678 [MUSIC] 2 00:00:04,678 --> 00:00:09,148 As we've been going along learning Ruby, we've been working with various types. 3 00:00:09,148 --> 00:00:13,620 Numbers, strings, arrays, and hashes. 4 00:00:13,620 --> 00:00:17,259 We haven't gotten too far along into what they actually are under the hood though. 5 00:00:18,280 --> 00:00:23,750 Although we've been calling these types, Ruby calls these things classes. 6 00:00:23,750 --> 00:00:27,430 The types that we've been using so far are all built into Ruby and 7 00:00:27,430 --> 00:00:32,510 come along with it when you download or install Ruby as part of Ruby's core API. 8 00:00:34,140 --> 00:00:37,400 We're not limited to working only with the built in classes that 9 00:00:37,400 --> 00:00:39,310 Ruby provides for us. 10 00:00:39,310 --> 00:00:41,510 We can also create our own. 11 00:00:41,510 --> 00:00:43,091 Why would we wanna do this? 12 00:00:43,091 --> 00:00:45,203 Well, I'm so glad you asked. 13 00:00:45,203 --> 00:00:47,290 As we're going along creating a program, 14 00:00:47,290 --> 00:00:50,540 it can be cumbersome to remember each small nuanced part of 15 00:00:50,540 --> 00:00:55,610 what we're working with and remember those parts in terms that computers understand. 16 00:00:56,910 --> 00:00:59,980 We start to abstract that away using representations of 17 00:00:59,980 --> 00:01:02,130 things we're used to in the real world. 18 00:01:03,270 --> 00:01:05,840 These representations are called classes. 19 00:01:07,330 --> 00:01:09,920 You can think of a class as a blueprint. 20 00:01:09,920 --> 00:01:14,150 The blueprint tells Ruby how a class should be structured and 21 00:01:14,150 --> 00:01:14,850 what it should do. 22 00:01:15,990 --> 00:01:20,460 For example, a blueprint of a car would show how a car can be made. 23 00:01:21,480 --> 00:01:26,440 What it doesn't do is get into the specific details about an individual car, 24 00:01:26,440 --> 00:01:27,020 like the color.