问题描述
我找不到任何直接适用于我查询的问题,因此我将此问题发布为一个新问题。
问题:
p>我要做一个关于C#编码指南的演示,但它不应该限制编码标准。所以我有一个大概的想法,但我认为我需要以解决良好的计划实践。
-
基本编码标准 - 外壳,格式化等。 >
-
良好做法 - 使用Hashset比其他数据结构,String vs String Builder,String的不变性并有效地使用它们
真的,我想添加更多的好做法(特别是提高性能。)所以喜欢听到一些更好的做法与C#使用。有什么建议么??? (不需要大的描述:)只是想法是足够了。)
不出所料,我刚刚发现了一个SO问题:
I couldn't find any question that directly applies to my query so I am posting this as a new question. If there is any existing discussion that may help me, please point it out and close the question.
Question:
I am going to do a presentation on C# coding guidelines but it is not supposed to limit to coding standards.
So I have a rough idea but I think I need to address good programing practices. So the contents will be something like this.
Basic coding standards - Casing, Formatting etc.
Good practices - Usage of Hashset over other data structures, String vs String Builder, String's immutability and using them effectively etc
Really I would like to add more good practices (Especially to improve the performance.) So like to hear some more good practices to be used with C#. Any suggestions??? (No need of large descriptions :) Just the idea is sufficient.)
Coding Guidelines for CSharp 3.0 and 4.0
Lance Hunt's C# Coding Standards
Brad Abrams' Internal Coding Guidelines
Unsurprisingly, I just found a SO question: C# Coding standard / Best practices
这篇关于编码指南+最佳实践?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!