how to add a delay in csharp

Code Example - how to add a delay in csharp

                
                        using System.Threading;

var delay = 1000;
Thread.Sleep(delay);