Possible Duplicate:
When are Getters and Setters Justified
Why exactly is having public and private accessors like these:
private string foo;
public string Foo
{
get
{
return foo;
}
set
{
foo = value;
}
}
considered better than just having public ones like this:
public string Foo;
The end result seems to be the same.