In a VB.NET I noticed that I'm able to create a property directly by using the Property keyword followed by the property name and the datatype without the need for the getter and setter method while I can't do this in C#!
Nevertheless, this property seems to be encapsulated as if I were put it in a getter and setter method!
Please take a look at the below screenshot.
In the screenshot above, the property I'm talking about is the number1, and I've created another property encapsulated in a getter and setter method called number2.
Then, I've created a new instance of the Class1 in the Class2, but I've noticed that the number1 property isn't exposed until I've created an instance of its class which is the same as if it was encapsulated in a getter and setter method like the number2 property!
Any explanations?