摘要:
readonly可以在构造函数中初始化,而const必须在声明时初始化 public class MyClass { public const int ConstValue = 10; public readonly int ReadOnlyValue = 10; public MyClass() 阅读全文
posted @ 2024-02-09 18:48
早起大王咻咻
阅读(12)
评论(0)
推荐(0)