title
C# Tutorial 5 Classes & OOP

description
Get the Code Here : https://goo.gl/p6mDqi Best C# Book : http://amzn.to/2iMArkU Support me on Patreon : https://www.patreon.com/derekbanas We start learning about object oriented programming in this part of my C# tutorial. We'll cover Classes, Methods, Fields, Constructors, Static Classes, Methods and Fields, Structs and Nullable Types. I'm going to cover OOP over a few videos to make sure everyone completely understands everything. For best results take notes on the cheat sheet provided above as you watch and leave any questions you have. Thank you to Patreon supporters like the following for helping me make this video facebook.com/cottageindustriesbuild/ jaryd remillard : instagram: @distant_admiration bugreplay.com @kyleaisho @thetwistedhat vjFaLk jaryd remillard : https://github.com/YearOfProgramming/2017Challenges

detail
{'title': 'C# Tutorial 5 Classes & OOP', 'heatmap': [{'end': 140.415, 'start': 114.694, 'weight': 0.85}, {'end': 615.208, 'start': 597.313, 'weight': 0.758}, {'end': 670.647, 'start': 644.41, 'weight': 0.883}, {'end': 1075.213, 'start': 1038.406, 'weight': 0.803}], 'summary': "Tutorial covers the creation and usage of structs and classes in c# and go, including fields, methods, constructors, and static classes, demonstrating the creation of a struct called 'rectangle' with methods to calculate area, object-oriented programming basics, creating constructors, and defining static utility classes with methods to calculate areas of shapes like rectangle, triangle, and circle.", 'chapters': [{'end': 281.435, 'segs': [{'end': 29.09, 'src': 'embed', 'start': 0.523, 'weight': 0, 'content': [{'end': 4.287, 'text': 'Well hello internet and welcome to part 5 of my C-sharp video tutorial.', 'start': 0.523, 'duration': 3.764}, {'end': 10.294, 'text': "In this part of the tutorial we're going to cover structs, classes, fields, methods, constructors, static, static classes,", 'start': 4.327, 'duration': 5.967}, {'end': 12.577, 'text': 'nullable types and a whole bunch more.', 'start': 10.294, 'duration': 2.283}, {'end': 19.064, 'text': 'Like always, all the code and a transcript of the video is available in the description underneath of the video, and I have a lot to do,', 'start': 12.617, 'duration': 6.447}, {'end': 19.945, 'text': "so let's get into it.", 'start': 19.064, 'duration': 0.881}, {'end': 23.108, 'text': 'Okay, so basic setup again.', 'start': 21.067, 'duration': 2.041}, {'end': 24.108, 'text': 'This is Visual Studio.', 'start': 23.148, 'duration': 0.96}, {'end': 26.709, 'text': 'Of course, if you are on a Mac, you can use Xamarin.', 'start': 24.168, 'duration': 2.541}, {'end': 29.09, 'text': "Now, the very first thing I'm going to talk about are structs.", 'start': 26.769, 'duration': 2.321}], 'summary': 'Part 5 of c# tutorial covers structs, classes, methods, constructors, static, static classes, nullable types, and more', 'duration': 28.567, 'max_score': 0.523, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4523.jpg'}, {'end': 99.394, 'src': 'embed', 'start': 43.035, 'weight': 1, 'content': [{'end': 48.497, 'text': 'So we are going to create a struct, and we are going to call it rectangle.', 'start': 43.035, 'duration': 5.462}, {'end': 54.238, 'text': 'And inside of this guy, we are going to define some different fields.', 'start': 49.014, 'duration': 5.224}, {'end': 60.243, 'text': 'And a field is just a way of describing whatever you are creating here.', 'start': 55.039, 'duration': 5.204}, {'end': 62.485, 'text': "Here we're describing rectangles.", 'start': 60.343, 'duration': 2.142}, {'end': 67.89, 'text': 'So I am going to define both a length as well as a width.', 'start': 62.645, 'duration': 5.245}, {'end': 73.048, 'text': 'Now you are also going to be able to create what is called a constructor method.', 'start': 68.803, 'duration': 4.245}, {'end': 77.634, 'text': 'And it will allow you to set values to these fields that you have right here.', 'start': 73.289, 'duration': 4.345}, {'end': 82.821, 'text': 'And the constructor method has exactly the same name as your struct.', 'start': 77.955, 'duration': 4.866}, {'end': 92.485, 'text': "So that'll be rectangle and I'm going to define a double here and length, and I'm going to give it a default value of one,", 'start': 83.274, 'duration': 9.211}, {'end': 99.394, 'text': "and then I'm going to create another one called W and it will have a default value of one as well.", 'start': 92.485, 'duration': 6.909}], 'summary': 'Creating a rectangle struct with length and width fields and a constructor method with default values.', 'duration': 56.359, 'max_score': 43.035, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_443035.jpg'}, {'end': 144.482, 'src': 'heatmap', 'start': 114.694, 'weight': 0.85, 'content': [{'end': 118.456, 'text': 'And then like I said we can also come in here and create methods.', 'start': 114.694, 'duration': 3.762}, {'end': 122.878, 'text': "And I'm going to create one that's going to return a double and it's going to be called area.", 'start': 119.136, 'duration': 3.742}, {'end': 129.252, 'text': "And it's just going to return whatever the length is times whatever the width is.", 'start': 123.55, 'duration': 5.702}, {'end': 130.192, 'text': 'Very simple.', 'start': 129.572, 'duration': 0.62}, {'end': 136.854, 'text': 'Now up inside of main now we are going to be able to come in here and go and create a rectangle struct.', 'start': 130.592, 'duration': 6.262}, {'end': 140.415, 'text': "So we'll go rectangle and let's just call this rect1.", 'start': 136.914, 'duration': 3.501}, {'end': 144.482, 'text': "We're going to be able to come in here and add values to it.", 'start': 141.277, 'duration': 3.205}], 'summary': 'Creating a method to return the area of a rectangle using length and width.', 'duration': 29.788, 'max_score': 114.694, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4114694.jpg'}, {'end': 281.435, 'src': 'embed', 'start': 246.109, 'weight': 2, 'content': [{'end': 249.952, 'text': "Rect2 And that's also how you would get values out of a struct.", 'start': 246.109, 'duration': 3.843}, {'end': 252.954, 'text': 'Oops, I want to make sure this is set to Rect2.', 'start': 250.132, 'duration': 2.822}, {'end': 261.201, 'text': "And what we're going to do here is just verify that Rect2's length is not 33, even though it was assigned to the value of Rect1,", 'start': 253.435, 'duration': 7.766}, {'end': 263.563, 'text': "just to prove that it's not a reference and it's a value.", 'start': 261.201, 'duration': 2.362}, {'end': 271.389, 'text': "And then, if we run this, you're going to see right here that the area was calculated for our rectangle and also that the length stayed at 200,", 'start': 263.783, 'duration': 7.606}, {'end': 274.391, 'text': 'just like we defined whenever the rect was first created.', 'start': 271.389, 'duration': 3.002}, {'end': 281.435, 'text': "Alright. so there's a rundown of how to create a struct, how to define a struct, a struct constructor,", 'start': 274.571, 'duration': 6.864}], 'summary': 'Demonstration of creating and using a struct in code, showing its value assignment and usage in calculations.', 'duration': 35.326, 'max_score': 246.109, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4246109.jpg'}], 'start': 0.523, 'title': 'Structs and classes in c# and go', 'summary': "Covers the creation and usage of structs and classes in c# and go, including fields, methods, constructors, static classes, and nullable types. it also demonstrates the creation of a struct called 'rectangle' with fields for length and width, a constructor method, and a method to calculate the area in a c# video tutorial. additionally, it delves into creating and using a struct in go to calculate the area of a rectangle and understanding value assignment versus reference assignment.", 'chapters': [{'end': 122.878, 'start': 0.523, 'title': 'C-sharp structs and classes', 'summary': "Covers structs, classes, fields, methods, constructors, static, static classes, nullable types, and more in a c-sharp video tutorial. it demonstrates the creation of a struct called 'rectangle' with fields for length and width, a constructor method to set default values, and a method to calculate the area.", 'duration': 122.355, 'highlights': ['The chapter covers structs, classes, fields, methods, constructors, static, static classes, nullable types, and more in a C-sharp video tutorial.', "It demonstrates the creation of a struct called 'rectangle' with fields for length and width, a constructor method to set default values, and a method to calculate the area."]}, {'end': 281.435, 'start': 123.55, 'title': 'Creating and using structs in go', 'summary': 'Demonstrates how to create and use a struct in go to calculate the area of a rectangle, assign values using a constructor, and understand value assignment versus reference assignment.', 'duration': 157.885, 'highlights': ['The chapter demonstrates how to create and use a struct in Go to calculate the area of a rectangle The chapter provides a demonstration of creating and using a struct in Go to calculate the area of a rectangle, showcasing the implementation of a rectangle struct and the calculation of its area.', 'Assign values using a constructor The chapter explains the process of assigning values to a struct using a constructor, illustrating the use of the constructor to define default values and create a rectangle with specific length and width.', 'Understand value assignment versus reference assignment The chapter clarifies the distinction between value assignment and reference assignment in structs, emphasizing that assigning one rectangle to another does not create a reference, and showcases the verification of value assignment through a practical example.']}], 'duration': 280.912, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4523.jpg', 'highlights': ['The chapter covers structs, classes, fields, methods, constructors, static, static classes, nullable types, and more in a C-sharp video tutorial.', "It demonstrates the creation of a struct called 'rectangle' with fields for length and width, a constructor method to set default values, and a method to calculate the area.", 'The chapter demonstrates how to create and use a struct in Go to calculate the area of a rectangle, showcasing the implementation of a rectangle struct and the calculation of its area.', 'Assign values using a constructor The chapter explains the process of assigning values to a struct using a constructor, illustrating the use of the constructor to define default values and create a rectangle with specific length and width.', 'Understand value assignment versus reference assignment The chapter clarifies the distinction between value assignment and reference assignment in structs, emphasizing that assigning one rectangle to another does not create a reference, and showcases the verification of value assignment through a practical example.']}, {'end': 806.379, 'segs': [{'end': 308.286, 'src': 'embed', 'start': 281.435, 'weight': 0, 'content': [{'end': 287.319, 'text': 'struct methods and how they pass by value instead of reference, and a whole bunch of other different things.', 'start': 281.435, 'duration': 5.884}, {'end': 293.143, 'text': 'And now what I want to talk about is object-oriented programming, or more specifically, how classes work.', 'start': 287.679, 'duration': 5.464}, {'end': 304.061, 'text': 'Now, a class is going to model a real-world object by defining the attributes of that real-world object, which we are going to call fields, and,', 'start': 294.392, 'duration': 9.669}, {'end': 308.286, 'text': "as well, the capabilities of that real-world object, which we're going to call methods.", 'start': 304.061, 'duration': 4.225}], 'summary': 'Introduction to object-oriented programming, covering class modeling and defining attributes and methods.', 'duration': 26.851, 'max_score': 281.435, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4281435.jpg'}, {'end': 471.508, 'src': 'embed', 'start': 442.07, 'weight': 2, 'content': [{'end': 449.173, 'text': "Now you're going to be able to create additional constructors as well, and because I defined both of these default values in here,", 'start': 442.07, 'duration': 7.103}, {'end': 451.094, 'text': "I technically don't have to create them,", 'start': 449.173, 'duration': 1.921}, {'end': 458.537, 'text': "but I just want to show you the fact that you can create them and you can overload constructors just like you're able to overload any other type of method,", 'start': 451.094, 'duration': 7.443}, {'end': 459.638, 'text': 'like we saw previously.', 'start': 458.537, 'duration': 1.101}, {'end': 464.242, 'text': "So I'm going to go public and animal and string,", 'start': 459.658, 'duration': 4.584}, {'end': 471.508, 'text': 'and with this one I am going to come in here and define what happens whenever they pass in only one string,', 'start': 464.242, 'duration': 7.266}], 'summary': 'Demonstrating overloading constructors and setting default values.', 'duration': 29.438, 'max_score': 442.07, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4442070.jpg'}, {'end': 625.73, 'src': 'heatmap', 'start': 597.313, 'weight': 4, 'content': [{'end': 602.597, 'text': "We're also going to be able to have what are called static fields, as well as methods,", 'start': 597.313, 'duration': 5.284}, {'end': 607.746, 'text': 'and these of course belong to the class and not the objects created for the class.', 'start': 602.597, 'duration': 5.149}, {'end': 615.208, 'text': "And it's very important to remember that a static field has the same value for all objects of the animal type.", 'start': 608.146, 'duration': 7.062}, {'end': 621.329, 'text': 'That means if its value changes for one animal object, it is going to change for all of them.', 'start': 615.388, 'duration': 5.941}, {'end': 625.73, 'text': "So let's say I want to keep track of every single animal that was ever created.", 'start': 621.409, 'duration': 4.321}], 'summary': 'Static fields and methods belong to the class, with the same value for all objects. they help keep track of created animal objects.', 'duration': 28.417, 'max_score': 597.313, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4597313.jpg'}, {'end': 670.647, 'src': 'heatmap', 'start': 644.41, 'weight': 0.883, 'content': [{'end': 648.432, 'text': 'And here we can just say num of animals, exactly like that.', 'start': 644.41, 'duration': 4.022}, {'end': 660.557, 'text': "Well, one thing we're going to have to do is go and increment number of animals inside of our constructor so that we know that a new animal object has been created.", 'start': 648.792, 'duration': 11.765}, {'end': 662.224, 'text': 'And we can paste that right there.', 'start': 661.004, 'duration': 1.22}, {'end': 663.725, 'text': 'And we can paste this right here.', 'start': 662.424, 'duration': 1.301}, {'end': 667.686, 'text': "Again, there's a lot of repetitive code just because I'm trying to keep everything very simple.", 'start': 663.925, 'duration': 3.761}, {'end': 670.647, 'text': "Next part of the tutorial, I'll show you how to streamline this stuff a little bit.", 'start': 667.786, 'duration': 2.861}], 'summary': 'Tutorial on incrementing number of animals and streamlining code.', 'duration': 26.237, 'max_score': 644.41, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4644410.jpg'}], 'start': 281.435, 'title': 'Oop basics and creating constructors', 'summary': 'Covers object-oriented programming basics, such as classes, attributes, and methods, with an example of inheritance and subclass creation. it also explains creating constructors, including overriding default constructors, defining default values, overloading constructors, and using static fields and methods in object creation and manipulation.', 'chapters': [{'end': 397.667, 'start': 281.435, 'title': 'Object-oriented programming basics', 'summary': 'Explains the basics of object-oriented programming, focusing on the concept of classes, their attributes, and methods, with an example of inheritance and subclass creation, and demonstrates how to create a class with specific attributes and methods to model real-world objects.', 'duration': 116.232, 'highlights': ['The chapter explains the basics of object-oriented programming, focusing on the concept of classes, their attributes, and methods, with an example of inheritance and subclass creation. It discusses the concept of classes, attributes, and methods, and provides an example of inheritance and subclass creation.', 'It demonstrates how to create a class with specific attributes and methods to model real-world objects. The tutorial explains the process of creating a class with specific attributes and methods to model real-world objects.']}, {'end': 806.379, 'start': 398.098, 'title': 'Creating constructors in oop', 'summary': 'Discusses creating constructors in object-oriented programming with examples, including overriding default constructors, defining default values, overloading constructors, creating static fields and methods, and using them in object creation and manipulation.', 'duration': 408.281, 'highlights': ['Creating and overriding constructors The chapter includes examples of creating and overriding constructors in object-oriented programming.', 'Defining default values and overloading constructors The transcript explains how to define default values and overload constructors, demonstrating the flexibility of constructor creation in OOP.', 'Using static fields and methods The usage of static fields and methods, including their behavior and impact on object creation, is thoroughly explained.']}], 'duration': 524.944, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4281435.jpg', 'highlights': ['The chapter explains the basics of object-oriented programming, focusing on classes, attributes, and methods, with an example of inheritance and subclass creation.', 'Demonstrates creating a class with specific attributes and methods to model real-world objects.', 'Creating and overriding constructors in object-oriented programming.', 'Defining default values and overloading constructors, demonstrating the flexibility of constructor creation in OOP.', 'Thorough explanation of using static fields and methods, including their behavior and impact on object creation.']}, {'end': 1155.471, 'segs': [{'end': 860.578, 'src': 'embed', 'start': 831.09, 'weight': 0, 'content': [{'end': 832.55, 'text': "And I don't need any of this stuff.", 'start': 831.09, 'duration': 1.46}, {'end': 833.671, 'text': 'All right.', 'start': 833.231, 'duration': 0.44}, {'end': 835.071, 'text': 'So here is shape math.', 'start': 833.731, 'duration': 1.34}, {'end': 845.135, 'text': "And just so you're aware, anytime you create a static class, I'm going to call this public static class.", 'start': 835.732, 'duration': 9.403}, {'end': 853.036, 'text': 'Anytime you create a static class, everything inside of it has to be a static method or a constant value.', 'start': 845.754, 'duration': 7.282}, {'end': 857.357, 'text': "So what we're going to do is we're going to create public static double.", 'start': 853.236, 'duration': 4.121}, {'end': 860.578, 'text': 'And this is going to be called get area.', 'start': 858.217, 'duration': 2.361}], 'summary': 'Introduction to creating a static class and method for calculating area.', 'duration': 29.488, 'max_score': 831.09, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4831090.jpg'}, {'end': 1075.213, 'src': 'heatmap', 'start': 1032.801, 'weight': 1, 'content': [{'end': 1038.006, 'text': 'And I can throw a rectangle in here like this, and then the length and the width.', 'start': 1032.801, 'duration': 5.205}, {'end': 1040.809, 'text': "And if we run it, we're going to see that that indeed works.", 'start': 1038.406, 'duration': 2.403}, {'end': 1042.89, 'text': 'Area of a rectangle comes back as 30.', 'start': 1041.089, 'duration': 1.801}, {'end': 1044.925, 'text': 'Okay So there you go.', 'start': 1042.89, 'duration': 2.035}, {'end': 1047.925, 'text': 'Static methods, static classes, static everything.', 'start': 1045.005, 'duration': 2.92}, {'end': 1051.646, 'text': 'And now because I have a little bit of time left, I want to talk about nullable types.', 'start': 1048.205, 'duration': 3.441}, {'end': 1056.107, 'text': 'Now data types by default cannot have a value of null.', 'start': 1052.186, 'duration': 3.921}, {'end': 1062.428, 'text': "And why that's sometimes bad is null is often needed whenever we are willing to work with databases.", 'start': 1056.387, 'duration': 6.041}, {'end': 1068.629, 'text': 'And it is very easy to make it so a data type will be able to hold a value of null.', 'start': 1062.908, 'duration': 5.721}, {'end': 1071.83, 'text': 'All you need to do is put the question mark after it like that.', 'start': 1068.909, 'duration': 2.921}, {'end': 1075.213, 'text': 'And then we could do something like random number is equal to null.', 'start': 1072.17, 'duration': 3.043}], 'summary': 'The transcript covers static methods, static classes, and nullable types in programming.', 'duration': 42.412, 'max_score': 1032.801, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_41032800.jpg'}, {'end': 1155.471, 'src': 'embed', 'start': 1118.094, 'weight': 5, 'content': [{'end': 1126.276, 'text': "And here we're going to come in and go has value, which is going to tell me if this actually has a value or if it is null by default.", 'start': 1118.094, 'duration': 8.182}, {'end': 1130.157, 'text': "And here we're also going to read random number is null.", 'start': 1126.716, 'duration': 3.441}, {'end': 1131.837, 'text': "And we're going to save it and run it.", 'start': 1130.437, 'duration': 1.4}, {'end': 1134.538, 'text': "And you're going to see it comes back as null both times.", 'start': 1132.237, 'duration': 2.301}, {'end': 1135.872, 'text': 'So there you go, guys.', 'start': 1135.051, 'duration': 0.821}, {'end': 1144.22, 'text': 'That is an introduction to structs as well as classes and nullable types and all those static classes and a whole bunch of other different things.', 'start': 1135.932, 'duration': 8.288}, {'end': 1149.765, 'text': "And in the next part of the tutorial, I'm going to get very heavily into object-oriented programming.", 'start': 1144.66, 'duration': 5.105}, {'end': 1153.729, 'text': 'And like always, please leave your questions and comments below.', 'start': 1150.126, 'duration': 3.603}, {'end': 1155.471, 'text': 'Otherwise, until next time.', 'start': 1154.29, 'duration': 1.181}], 'summary': 'Introduction to structs, classes, and nullable types with examples. next part: object-oriented programming.', 'duration': 37.377, 'max_score': 1118.094, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_41118094.jpg'}], 'start': 806.699, 'title': 'Creating static utility classes', 'summary': 'Demonstrates the creation of a static utility class called shape math, defining a static method to calculate areas of different shapes such as rectangle, triangle, and circle, and covers the usage of static classes and methods to calculate the area of a rectangle, yielding an output of 30. it also introduces the concept of nullable types to handle null values and provides an introduction to structs, classes, and object-oriented programming.', 'chapters': [{'end': 1006.007, 'start': 806.699, 'title': 'Creating static utility classes', 'summary': 'Demonstrates creating a static utility class called shape math, defining a static method get area to calculate areas of different shapes, and handling different shape calculations such as rectangle, triangle, and circle.', 'duration': 199.308, 'highlights': ['Define a static utility class called shape math and create a public static method get area to calculate areas of different shapes, such as rectangle, triangle, and circle.', 'The get area method handles different shape calculations by using conditional statements to compare the shape string and perform corresponding area calculations.', "All methods within a static class must be static, and the chapter emphasizes the importance of using the 'public' access modifier to enable calling the method from outside the class."]}, {'end': 1155.471, 'start': 1006.007, 'title': 'Static classes, methods and nullable types', 'summary': 'Covers the usage of static classes and methods to calculate the area of a rectangle, yielding an output of 30, and the concept of nullable types to handle null values, showcasing the use of the question mark notation to enable null as a value for data types, and demonstrating null value checks in different ways, resulting in a null value both times. additionally, an introduction to structs, classes, and the promise of delving into object-oriented programming in the next part is provided.', 'duration': 149.464, 'highlights': ['The chapter covers the usage of static classes and methods to calculate the area of a rectangle, yielding an output of 30. Demonstrates the usage of a static class and method to calculate the area of a rectangle, resulting in an output of 30.', 'The concept of nullable types is introduced, showcasing the use of the question mark notation to enable null as a value for data types. Introduces the concept of nullable types and demonstrates the use of the question mark notation to enable null as a value for data types.', 'Null value checks are demonstrated in different ways, resulting in a null value both times. Shows different methods for null value checks, resulting in a null value both times.', 'An introduction to structs, classes, and the promise of delving into object-oriented programming in the next part is provided. Introduces structs, classes, and promises to cover object-oriented programming in the next part of the tutorial.']}], 'duration': 348.772, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/GAvhe6oe-_4/pics/GAvhe6oe-_4806699.jpg', 'highlights': ['Define a static utility class called shape math and create a public static method get area to calculate areas of different shapes, such as rectangle, triangle, and circle.', 'The chapter covers the usage of static classes and methods to calculate the area of a rectangle, yielding an output of 30.', 'The get area method handles different shape calculations by using conditional statements to compare the shape string and perform corresponding area calculations.', 'The concept of nullable types is introduced, showcasing the use of the question mark notation to enable null as a value for data types.', "All methods within a static class must be static, and the chapter emphasizes the importance of using the 'public' access modifier to enable calling the method from outside the class.", 'Null value checks are demonstrated in different ways, resulting in a null value both times.', 'An introduction to structs, classes, and the promise of delving into object-oriented programming in the next part is provided.']}], 'highlights': ['The chapter covers the creation and usage of structs and classes in C# and Go, including fields, methods, constructors, and static classes.', "The chapter demonstrates the creation of a struct called 'rectangle' with fields for length and width, a constructor method to set default values, and a method to calculate the area.", 'The chapter explains the basics of object-oriented programming, focusing on classes, attributes, and methods, with an example of inheritance and subclass creation.', 'Define a static utility class called shape math and create a public static method get area to calculate areas of different shapes, such as rectangle, triangle, and circle.', 'The chapter covers the usage of static classes and methods to calculate the area of a rectangle, yielding an output of 30.']}