gpt4 book ai didi

c# - { 得到;放; } 在变量声明中

转载 作者:太空宇宙 更新时间:2023-11-03 20:07:32 29 4
gpt4 key购买 nike

<分区>

我在一本书上找到这样声明变量的方法:

class JerseyNumber
{
public string Player { get; private set; }
public int YearRetired { get; private set; }

string JerseyNumber(string player, int numberRetired)
{
Player = player;
YearRetired = numberRetired;
}
}

如果我删除代码会发生什么变化:

{ get; private set; }

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com