>Console.Write( (Int32) (2.050000000000000043 * 100)); >>this will print 204 instead of 205. The reason you see a difference between the tools in your example has to do with the number of digits. .NET uses 15 significant digits, VFP uses 18. Your sample has the flipping digit at position 16. You get the same result as in C# when you change that number:
>Set Fixed On >Set Decimals To 9 >? 550000.8150000000000000000000000000 >check the internal binary.
In VFP is 0h40699FFFFFFFFFFF, then INT part is 204 In MS SQL with decimal literal is 0x4069A00000000000, then INT part is 205 In MS SQL with floating point literal is 0h40699FFFFFFFFFFF, then INT part is 204