diff --git a/chap5_essential_language_features/automatically_implemented_properties/Program.cs b/chap5_essential_language_features/automatically_implemented_properties/Program.cs index 41a85ff..c58a3da 100644 --- a/chap5_essential_language_features/automatically_implemented_properties/Program.cs +++ b/chap5_essential_language_features/automatically_implemented_properties/Program.cs @@ -21,11 +21,16 @@ namespace automatically_implemented_properties public class Product { private string name; + + public int ProductID { get; set; } public string Name { - get { return name; } + get { return ProductID + name; } set { name = value; } } + public string Description { get; set; } + public decimal Price { get; set; } + public string Category { set; get; } } } \ No newline at end of file