English
Topic 12. Operator overloading, indexers, and extension methods
Goal: become familiar with operator overloading, conversion operators, indexers, and extension methods in C#; learn to declare arithmetic and comparison operators consistently with Equals, create indexers with bounds checking, and extend built-in types with extension methods.
Lecture contents
- Operator overloading — Operator overloading · Conversion operators
- Indexers — Indexers
- Extension methods — Extension methods
- Examples and common mistakes — Example programs · Common mistakes