public class CustomerInfo
{
private string _name;
public string Name
{
get
{
return _name;
}
set
{
_name = value ;
}
}
}
class Student
{
public int Age { get; set; }
}
{
title = aTitle;
director = aDirector;
Rating = aRating;
}
public string Rating
{
get { return rating; }
set
{
if(value == "G" || value == "PG" || value == "PG13" || value =="R" || value == "NR")
{
rating = value;
} else
{
rating = "NR";
}
}
}