> ## Documentation Index
> Fetch the complete documentation index at: https://interview.anantapoudel.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Introduction

A complete, structured guide for mastering .NET and C# at an intermediate and senior level.\
This documentation is divided into five main pillars, each containing detailed technical topics, best practices, and interview-grade explanations.

***

## 1. C# Language & Core Programming

This section builds a strong foundation in the C# language and its underlying concepts.

### C# Language Fundamentals

* Data types, variables, and constants
* Value types vs reference types
* Type casting and conversions
* Nullable types
* `var`, `dynamic`, and `object`
* Strings and interpolation
* Control flow (`if`, `switch`, loops)
* Arrays and collections
* Structs and enums
* `readonly` and `const`
* Pattern matching
* Tuples and deconstruction
* Indexers and ranges (`^`, `..`)
* XML documentation

### Object-Oriented Programming (OOP)

* Classes and objects
* Inheritance and polymorphism
* Abstract classes and interfaces
* Encapsulation and access modifiers
* Constructors and destructors
* Static members and singletons
* Sealed classes
* Partial classes and records
* Method hiding (`new`)
* Virtual vs override

### Advanced C# Concepts

* Delegates and events
* Lambda expressions
* Extension methods
* Reflection and attributes
* Generics and constraints
* Nullable reference types
* Expression-bodied members
* Records and immutability
* Operator overloading
* File-scoped namespaces
* Global using directives
* `Span<T>` and `Memory<T>`

***

## 2. Collections, LINQ & Asynchronous Programming

Master the tools that make .NET development fast, expressive, and scalable.

### Collections & Generics

* Arrays, Lists, Dictionaries, HashSet, Queues, Stacks
* ReadOnlyCollection and concurrent collections
* Immutable collections

### LINQ

* Query syntax vs method syntax
* Filtering, projection, grouping, joining
* Aggregation functions
* Deferred vs immediate execution
* Custom extension methods
* Parallel LINQ (PLINQ)

### Asynchronous Programming

* Tasks and threads
* `async` and `await` pattern
* Task-based Asynchronous Pattern (TAP)
* `Task.WhenAll` and `Task.WhenAny`
* Synchronization (`lock`, `SemaphoreSlim`)
* Cancellation tokens
* Deadlocks and prevention
* Background services and hosted services
* Using `ValueTask` for performance

***

## 3. ASP.NET Core, Web API, EF Core & Architecture

This section covers the main components of building robust backend applications with .NET.

### .NET Core Fundamentals

* CLR, JIT compilation, GC
* Project structure (`Program.cs`, hosting model)
* Kestrel web server
* Middleware pipeline
* Configuration providers
* Dependency injection system

### ASP.NET Core MVC & Razor

* Controllers, views, and models
* Razor syntax, layouts, partial views
* Tag helpers
* Model binding and validation
* ViewData, ViewBag, TempData
* Anti-forgery tokens

### ASP.NET Core Web API

* `[ApiController]` basics
* Routing and attribute routing
* Action results and response shaping
* Swagger/OpenAPI
* File uploads and streaming
* Pagination, filtering, sorting
* API throttling and rate limiting

### Entity Framework Core (EF Core)

* `DbContext` and `DbSet`
* Code-first migrations
* Relationship configuration
* Loading strategies (lazy/eager/explicit)
* Transactions and concurrency
* Change tracking
* Raw SQL execution
* Repository and Unit of Work patterns

### SQL Server & Data Design

* Normalization vs denormalization
* Indexes and keys
* Joins and query optimization
* Stored procedures, views, triggers
* CTEs and window functions

***

## 4. Security, Testing, Performance & Deployment

A senior .NET developer must excel in building secure, performant, and well-tested systems.

### Authentication & Authorization

* ASP.NET Core Identity
* Claims and roles
* Policy-based authorization
* JWT authentication
* OAuth2 and OpenID Connect
* Refresh tokens
* External providers

### Validation & Middleware

* Data annotations
* Custom validation attributes
* FluentValidation
* Custom middleware
* Filters (resource, action, exception)

### Performance & Caching

* In-memory and distributed caching
* Response and output caching
* Compression middleware
* EF query optimization
* BenchmarkDotNet
* Asynchronous I/O

### Logging & Monitoring

* `ILogger<T>` usage
* Serilog, NLog integration
* Centralized logging (Seq, ELK, App Insights)
* Distributed tracing with OpenTelemetry
* Health checks

### Testing

* xUnit, NUnit, MSTest
* Moq for mocking
* FluentAssertions
* EF Core in-memory testing
* Integration testing with `TestServer`

***

## 5. Microservices, Messaging, Cloud & System Design

Master modern distributed system design with .NET and cloud platforms.

### Microservices & Distributed Systems

* Microservices principles
* Communication patterns (HTTP, gRPC)
* API gateways (Ocelot, YARP)
* Resilience with Polly (retry, circuit breaker)
* Distributed tracing and correlation IDs

### Messaging & Background Jobs

* RabbitMQ, Kafka, Azure Service Bus
* Background workers (`IHostedService`)
* Worker Service templates
* Hangfire / Quartz.NET scheduling
* Event-driven design

### Cloud Deployment & DevOps

* Docker and multi-stage builds
* Kubernetes basics
* CI/CD pipelines (GitHub Actions, Azure DevOps)
* Monitoring (Prometheus, Grafana)
* Deployment slots and rolling updates

### Architecture & System Design

* Clean Architecture
* Onion Architecture
* CQRS and Mediator pattern
* Event Sourcing and DDD
* Monolith vs microservices
* Load balancing and caching
* Database sharding and partitioning
* Idempotent API design

***

# Start Learning

Choose a topic below to begin your .NET learning journey.

<Columns cols={2}>
  <Card title="C# Language & Core Programming" href="/dotnet/fundamentals/csharp">
    Learn the fundamentals and deeper internals of the C# language.
  </Card>

  <Card title="Collections, LINQ & Async" href="/dotnet/fundamentals/collections">
    Master LINQ, generics, tasks, async/await, and advanced C# features.
  </Card>

  <Card title="ASP.NET Core, Web API & EF Core" href="/dotnet/core/webapi">
    Build robust backend applications using Web API and EF Core.
  </Card>

  <Card title="Security, Testing & Performance" href="/dotnet/core/security">
    Learn how to secure, test, and optimize enterprise .NET applications.
  </Card>

  <Card title="Microservices, Cloud & System Design" href="/dotnet/system/architecture">
    Advanced architecture, messaging, cloud deployments, and distributed systems.
  </Card>
</Columns>
