Getting C# Ready (Windows Setup)
Unlike HTML, C# doesn’t live in your browser. It runs through a full development environment called Visual Studio. That sounds heavy, but you’re about to see it’s just another playground — and you only have to set it up once.
Follow these steps and you’ll have a working C# sandbox in under fifteen minutes.
C# projects are easiest to build in Visual Studio Community — Microsoft’s free, full‑featured IDE.
- Open your browser and go to visualstudio.microsoft.com.
- Click Download under Visual Studio Community.
- Run the installer once it finishes downloading.
When the Visual Studio Installer opens, you’ll see a list of workloads — bundles of tools for different kinds of development.
For this book, you only need the .NET tools.
- In the installer, check .NET desktop development.
- Leave everything else unchecked unless you already know you need it.
- Click Install and let it run. This may take a few minutes.
When it finishes, click Launch to open Visual Studio.
We’ll start with the simplest possible sandbox: a console app that prints text.
- In Visual Studio, click Create a new project.
- Search for Console App (C#).
- Select Console App and click Next.
- Name it PlayFirstCSharp and choose a folder you can find easily.
- Click Create.
Visual Studio will open a file called Program.cs with some starter code already inside.
Look for a line that prints something to the console, like:
To run it, click the green Run button at the top (or press F5).
A black console window will appear showing:
That’s your C# sandbox saying hello. You’re officially up and running.
The tools changed — browser to Visual Studio — but the loop is exactly the same:
The AI will write the first C# version. You’ll run it, twist the knobs, and break it on purpose. Visual Studio is just the new playground where that happens.