In this program, we are going to share C# program to add two timespans with the output.
To increase your C# knowledge, practice all C sharp programs:
Copy the below c# program and execute it in your Microsoft Visual Studio IDE (Integrated Development Environment ). At the end of this program, I have shared the output program.
static void Main()
TimeSpan s1 = new TimeSpan(5, 0, 0);
TimeSpan s2 = new TimeSpan(1, 45, 10);
TimeSpan s3 = s1.Add(s2);