Getters and Setters as functions?

So I know in C++ that I should use a GET and a SET function to access my variables from other places. However in C# this seems to be a property. So my question is should I not use functions for my GET and SET and instead use the c# style?

At the moment my code looks like this:

    /// <summary>
    /// Highest tempruture during the different weathers. 
    /// </summary>
    protected float _fHighestTemp;

    /// <summary>
    /// This is our GET function for reading the value. 
    /// </summary>
    public float GetHighestTemp() { return _fHighestTemp; }
    /// <summary>
    /// This is our SET function this one we use to set the highest temprature we could have during different weather. 
    /// </summary>
    public void SetHighestTemp(float SetHighestTemp) { _fHighestTemp = SetHighestTemp; }

Is there any downside to using it with functions? (More memory heavy, or anything else)
And could if not, why is it better to use the c# way where its properties instead?

Sorry for the noob question but I really would like to know before I go into a Unity project the wrong way and have to go back and redo it all.

You should do it the C# way if only because it’s more idiomatic that way. Also, there may be special optimizations for simple accessor-like properties within the CLR or JIT or whatever.

Also, note that in C# and Unity in general, the standard is to use public member’s for anything users can generally set and get. Properties are only used when you want to do things like read but not write, sanitize inputs, call functions when a thing is set, etc.

I know this question is old as balls, but that is the official answer.

I have another question for this now that I started working with c# getters and setters as I understood them. The problem I see is that why should I make public variable that looks like this:

// Variable
private int _iRandomNumber
// Getter and setter
public int iRandomNumber
     get { return _iRandomNumber; }
     set { _iRandomNumber = value; }


I don’t see the point of that since what different would it then be to just make the variable public since it’s anyway got the get and set in the same bracket?

However if I do like this:

// Variable
private int _iRandomNumber
// Getter and setter
public int GetiRandomNumber { get { return _iRandomNumber; } }
public int SetiRandomNumber { set { _iRandomNumber = value; } }

Then when I try to use my SetiRandomNumber by itself Unity complier complains that I cannot use my SetProperty since I do not have a GET property inside my SET. Should I really have to make it like the first example I wrote because as I wrote then what’s the point of Getters and Setters in c#?

Or should I instead move away from them, like I asked from the beginning and make functions for each Get and Set like in c++ so I can actually use them by themself?