
Already know some of this? A 2-minute test skips the lessons you know.
Take the placement testA free 33-lesson course built from Code Monkey's 4h 35m of YouTube video. 3 days at 90 minutes a day, with study notes and a quiz in every lesson. A 2-minute placement test skips what you already know.
Taught by Code Monkey on YouTube. Videos play in YouTube's own player, so the creator keeps every view.
Understand the full list of advanced C# topics covered in this course, from reflection and extension methods to multithreading and unsafe code.
Use System.Reflection to inspect types, methods, and fields at runtime, invoke methods dynamically, and create instances via Activator without compile-time references.
Create static methods in static classes with a 'this' first parameter to extend types you cannot modify, such as built-in or third-party classes.
Define a parameterless static constructor to run initialization logic exactly once per class, before any static members are accessed or instances created.
Use nameof to get the string name of a type, field, or method at compile time, avoiding hardcoded strings and improving refactoring safety.
Use the default keyword to get the default value of any type, including generics, without hardcoding literals like 0, false, or null.
Define record types with positional parameters for immutable data storage, value-based equality, and with-expressions for non-destructive updates.
Use ?. and ?[] to safely access members or indexers only when the receiver is non-null, avoiding NullReferenceExceptions.
Use ?? to return a fallback value when an expression is null, and ??= to assign only if the left side is null, ideal for lazy initialization.
Configure the static Main entry point with optional string[] args or int return codes, parse arguments with TryParse, and set the startup object in multi-class projects.
Append ? to value types (int?, bool?, struct?) to allow null assignment, enabling clearer 'no value' semantics than sentinel values like -1.
Use Span to reference array segments without copying data, enabling high-performance slicing, sorting, and parsing on arrays, strings, and memory.
Apply &, |, ^, ~, <<, >> to manipulate individual bits, build compact flags, and understand two's complement for signed integers.
Decorate enums with [Flags] and powers-of-two values to store multiple enum options in a single field, using bitwise operations and HasFlag.
Use #define, #if, #else, #elif, #endif to include or exclude code at compile time based on symbols, enabling debug-only builds and per-file configuration.
Use out for required output parameters, ref for read-write reference passing, and in for read-only reference passing to avoid struct copying overhead.
Understand how value types are boxed into object references on the heap, the performance cost, and why to prefer generics over object lists.
Use dynamic to defer type checking to runtime, enabling work with unknown schemas like JSON, while accepting loss of IntelliSense and compile-time safety.
Implement this[int index] { get; set; } to allow instances to be accessed with square brackets, supporting custom logic and read-only or read-write modes.
Create custom attribute classes inheriting from System.Attribute, apply them to code elements, and retrieve them via reflection for validation or tooling.
Instantiate compiler-generated types with new { Prop = value } for temporary, read-only data organization, useful in LINQ projections but not for long-term storage.
Use (type1, type2) syntax or ValueTuple for mutable, named or positional groups; deconstruct into variables with (var a, var b) = tuple; return multiple values from methods.
Implement IDisposable and wrap resources in using blocks to guarantee Dispose() runs, even on exceptions, for unmanaged resource cleanup.
Define static operator +, -, ==, !=, etc., for custom types to enable natural syntax like player1 + player2, and implement IEquatable for performance.
Use Where, Select, OrderBy, GroupBy, Join, and query syntax (from x in list where ...) to filter and transform collections with deferred execution.
Create .NET 8 Windows Forms projects, drag controls from the Toolbox, handle Click events, and modify control properties in the designer for visual apps.
Use [DllImport] with extern static methods to call Windows API functions like MessageBox, and understand layer masks as bitwise flags in Unity.
Use Debug.Assert for compile-time-excluded runtime checks, and adopt frameworks like MSTest, NUnit, or xUnit for automated unit testing.
Enable 'Allow unsafe code', use unsafe blocks, stackalloc, pointers (int*), fixed, and pointer arithmetic to bypass memory safety for interop or extreme performance.
Mark methods async, return Task or Task, await long-running operations like HTTP calls, and run multiple tasks concurrently with Task.WhenAll without multithreading.
Create Thread instances, fix race conditions with lock(object), avoid deadlocks, use ThreadPool for short work, and prefer Unity Job System for game development.
Review all advanced topics: reflection, extensions, static constructors, typeof, nameof, sizeof, default, expression bodies, records, null operators, ternary, Main args, nullable, Span, bitwise, enum flags, preprocessor, ref/out/in, boxing, dynamic, indexers, attributes, anonymous types, tuples, using/IDisposable, operators, LINQ, WinForms, DllImport, assert, unsafe, async/await, multithreading.