Creating throwaway projects in Visual Studio
Quick tip: did you know you can easily create "throwaway" test projects in Visual Studio?
In Visual Studio settings, simply uncheck "Save new projects when created"
By the way (bonus tip), you can easily find settings just by using the Quick Launch feature in the newer versions of Visual Studio (2012 and later):
Anyway, once you've done this, you can create a new project, give it a name, and worry about saving it later (if ever). I use this all the time for testing out various experiments.
Note that it doesn't work with all project types, unfortunately.
You can do a lot, but if you try to add an external reference, or another project, or a NuGet package, you'll have to save. Otherwise, once you're done, when you close the solution, you'll be prompted whether to save it or throw it away:
Depending on how simple the experiment is that you want to run, another possible testbed is the "C# Interactive Window" in recent versions of Visual Studio (2015 and later), accessible from the View menu (or use the Quick Launch!)
Anyway, hopefully this helps you in your programming experiments! Knowing your tools well can save you a lot of time.