I'm a novice of programming who's learning C# recently.
When reading my textbook, I see the code below:
public class Panda
{
public Panda Mate;
public void Marry(Panda partner)
{
Mate = partner;
partner.Mate = this;
}
}
The book says that this
here is used to set the mate
field of partner
, but I don't know what does that mean.
I'll be a big help if someone can explain it to me.