Complete the code to declare an auto-implemented property named Name of type string.
public class Person { public string [1] { get; set; } }
The property name should be Name with a capital letter to follow C# naming conventions.
Complete the code to declare an auto-implemented property named Age of type int.
public class Person { public [1] Age { get; set; } }
string or bool for age.double.The property Age should be of type int to represent whole numbers.
Fix the error in the auto-implemented property declaration by completing the code.
public class Product { public decimal [1] { get; set; } }
Property names should start with a capital letter, so Price is correct.
Fill both blanks to declare an auto-implemented property named IsAvailable of type bool.
public class Item { public [1] [2] { get; set; } }
boolean instead of bool.Available.The property type is bool and the name is IsAvailable.
Fill all three blanks to declare an auto-implemented property named Title of type string with public get and private set accessors.
public class Book { public [1] [2] { get; [3] set; } }
The property type is string, the name is Title, and the setter is private to restrict write access.