If you want to test little snippets of code in Visual Studio before having to change your code and having to launch and debug your app, check out the Interactive window via the View -> Other Windows -> C# Interactive menu option.
The C# Interactive window is a REPL Editor, i.e. Read-Evaluate-Print-Loop and can be useful for things like
– checking date formats (shown below)
– declaring and testing methods
– testing strings – interpolation, substring, replace, trim etc.
– testing LINQ queries on declared collections