// Thread Sleep vs Task Delay int delayInSec = 3; // Using Thread Sleep Thread.Sleep(delayInSec * 1000); // Using Task Delay Task.Delay(delayInSec * 1000).Wait();