Check out example codes for "c# one line set". It will help you in understanding the concepts better.

Code Example 1

public class Location
{
   private string locationName;

   public Location(string name) => Name = name;

   public string Name
   {
      get => locationName;
      set => locationName = value;
   }
}

Learn ReactJs, React Native from akashmittal.com