Question: I'm hitting something here which is very odd but I'm not sure whether it's me knowing the TimeSpan APIs 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);

```

Doesn't `TimeSpan.FromMilliseconds` take millisecond precision into account while doing the comparison?

Answer: 
`TimeSpan` simply rounds the number of milliseconds that you pass it, so both `123.33` and `123.34` end up representing a timespan of 123 milliseconds. `123.5` would be rounded up to 123 milliseconds.

If you need better precision, do the math with the ticks yourself:

```
var foo = TimeSpan.FromTicks((long)(123.34*TimeSpan.TicksPerMillisecond));
var bar = TimeSpan.FromTicks((long)(123.33*TimeSpan.TicksPerMillisecond));
Console.WriteLine(foo > bar);

```

Now your program produces `True` ([demo](http://ideone.com/0oT1nZ)).
Timespan accepts a floating point as a parameter for milliseconds but ignores the decimals.

Makes sense, as timespan has no notion of sub-milliseconds; it's the smallest unit.