I find something here, which is very strange, but I'm not sure if it is wrong. The following prints out false, and I'm not sure why:
var foo = TimeSpan.FromMilliseconds(123.34d);
var bar = TimeSpan.FromMilliseconds(123.33d);
Console.WriteLine(foo > bar);
The following prints true:
var foo = TimeSpan.FromMilliseconds(123.34d);
var bar = TimeSpan.FromMilliseconds(123.33d);
Console.WriteLine(foo == bar);
Does the TimeSpan.FromMillisecondsaccuracy of milliseconds take into account when performing the comparison?
source
share