C# 14 · Basics

Declare variables

Use var when the type is obvious. const values must be known at compile time.

var count = 3;
const double Pi = 3.14159;
string name = "Ada";

Official C# 14 documentation

More basics commands

All basics commands · C# 14 cheatsheet

Was this page helpful?