using System;
class SecondsBetweenTwoDates
{
static void Main()
{
DateTime startDate = new DateTime(2025, 1, 12);
DateTime endDate = new DateTime(2025, 1, 13);
// Calculate the difference between the two dates
TimeSpan timeDifference = endDate - startDate;
// Get the total number of seconds
double totalSeconds = timeDifference.TotalSeconds;
Console.WriteLine($"The number of seconds between the two dates is: {totalSeconds}");
}
}
/*
run:
The number of seconds between the two dates is: 86400
*/