Summary

You spent the preceding chapter learning the theory, and now you've seen some of the practice behind the most powerful concept in C#. Hopefully by this point, you've seen how you can model just about anything with carefully defined classes and methods. You may have noticed a few limitations of the methods we've shown you so far, though. For example, methods can return only a single value—what if you want to manipulate and return two or more values? Or what if you're not quite sure how many parameters you'll have when you call the method? Maybe you'll create a Dog object with a name and a weight, but perhaps sometimes you just have the name, and you'll need to add the weight later. C# methods are flexible enough to handle all of these cases, and in the next chapter, you'll spend time looking at them more closely.