- Why don't we put our newly found Lists skills to good use…and create a class that uses them.…I'm going to move my interactive window down…and I'll come over to Solution Explorer,…I'll go into my EssentialTrainingProject,…I'll add a class by right-clicking the project,…selecting Add, and then selecting Class.…With Class selected at the top,…I'll name my class AwesomeSauce.…
In the AwesomeSauce window,…I'll go ahead and make my class public…because I know that later I'll want to test this.…And now let's add in our list.…So I'll create public List…and it's going to be a type string.…And I'll call this particular property Sauces.…One thing I want to point out at this juncture is…that the list classes are actually part of…System.Collections.Generic,…and we have a using for this.…
Visual Studio automatically puts…System.Collections.Generic in…every time you create a new class.…So that was already there but you'll note…that now it's sort of lit up.…The other two are not meaning we haven't…really used anything from those name spaces yet.…
AuthorBruce Van Horn
- Writing unit tests in C#
- Working with simple and multidimensional arrays
- Managing ordered and unordered data with lists
- Evaluating conditions with if-else statements
- Using OR, AND, and NOT operators
- Building loops
- Debugging and handling exceptions
- Creating the final build of your C# project
Skill Level Beginner
C# Object-Oriented Programming Tips and Trickswith Jesse Freeman58m 39s Intermediate
1. Unit Testing and Test-Driven Development
2. Arrays and Collections
3. Flow Control
4. Exception Handling
5. Getting to Production
Next steps1m 57s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.