C# 程式設計手冊C# programming guide

本節提供可透過 .NET Framework 存取 C# 的重要 C# 語言特性與功能的詳細資訊。This section provides detailed information on key C# language features and features accessible to C# through the .NET Framework.

本節內容中大部分會假設您已經了解一些 C# 和一般程式設計概念。Most of this section assumes that you already know something about C# and general programming concepts. 如果您是程式設計或 C# 的新手,建議先瀏覽 C# 快速入門C# 使用者入門 (英文) 互動式教學課程,這些內容不需要事先具備程式設計知識。If you are a complete beginner with programming or with C#, you might want to visit the C# Quickstarts or Getting Started with C# interactive tutorial, where no prior programming knowledge is required.

如需特定關鍵字、運算子和前置處理器指示詞的相關資訊,請參閱 C# 參考For information about specific keywords, operators and preprocessor directives, see C# Reference. 如需 C# 語言規格的相關資訊,請參閱 C# 語言規格For information about the C# Language Specification, see C# Language Specification.

程式區段Program sections

C# 程式內部Inside a C# Program

Main() 和命令列引數Main() and Command-Line Arguments

語言章節Language Sections

陳述式、運算式和運算子Statements, Expressions, and Operators

型別Types

類別和結構Classes and Structs

介面Interfaces

列舉型別Enumeration Types

委派Delegates

陣列Arrays

字串Strings

屬性Properties

索引子Indexers

事件Events

泛型Generics

迭代器Iterators

LINQ 查詢運算式LINQ Query Expressions

Lambda 運算式Lambda Expressions

命名空間Namespaces

可為 Null 的型別Nullable Types

Unsafe 程式碼和指標Unsafe Code and Pointers

XML 文件註解XML Documentation Comments

平台章節Platform Sections

應用程式定義域Application Domains

組件和全域組件快取Assemblies and the Global Assembly Cache

屬性Attributes

集合Collections

例外狀況和例外狀況處理Exceptions and Exception Handling

檔案系統和登錄 (C# 程式設計指南)File System and the Registry (C# Programming Guide)

互通性Interoperability

反映Reflection

請參閱See Also