相关疑难解决方法(0)

常量的C#命名约定?

private const int THE_ANSWER = 42;
Run Code Online (Sandbox Code Playgroud)

要么

private const int theAnswer = 42;
Run Code Online (Sandbox Code Playgroud)

我个人认为在现代IDE中我们应该使用camelCase,因为ALL_CAPS看起来很奇怪.你怎么看?

c# const naming-conventions

391
推荐指数
9
解决办法
18万
查看次数

标签 统计

c# ×1

const ×1

naming-conventions ×1