// 1 - 0.00000000000000000000000000000000000001 = 0.99999999999999999999999999999999999999
TdDecimal left01 = new TdDecimal(1, 0, 0, 0, 1, 0); // left01 = 1
TdDecimal right01 = new TdDecimal(1, 0, 0, 0, 38, 38); // right01 = 0.00000000000000000000000000000000000001
TdDecimal result01 = left01 - right01;
Console.WriteLine("{0} - {1} = {2}", left01, right01, result01);
// 3.4538475968734 - 0.4538475968734 = 3
TdDecimal left02 = TdDecimal.Parse("3.4538475968734");
TdDecimal right02 = TdDecimal.Parse("0.4538475968734");
TdDecimal result02 = left02 + right02;
Console.WriteLine("{0} - {1} = {2}", left02, right02, result02);
// In the following example, an OverflowException will be thrown when subtracting the numbers
// 15.98798734398453 - 100,445,234,554,774,908,493,123,496,675
// An OverflowException is thrown because when the scale of the right operand is adjusted to
// match the scale of the left operand, the precision of the right will be greater than the MaxPrecision
TdDecimal except02 = TdDecimal.Parse("15.98798734398453") + TdDecimal.Parse("100445234554774908493123496675");