When I was in university 6-8 years ago, I learned that it was common practise to have public get and set methods but private variables when using Java. However these days, when I use C#, I realise that a lot of the common class variables have public accessibility, e.g. String.Length.
Is it common practise in C# to make variables public (so is it widely accepted that people can program in such a manner)?
Thanks