Decimal.MinusOne
is a decimal field in C#. It represents the number negative one (-1
).
public static readonly decimal MinusOne;
The value returned is minus one (-1
).
// use Systemusing System;// create classclass HelloWorld{static void Main(){// print the fieldConsole.WriteLine(Decimal.MinusOne);// create decimal valuesdecimal decimalNumberOne = Decimal.MinusOne;decimal decimalNumberTwo = 3.4m + Decimal.MinusOne;decimal decimalNumberThree = 10.00m / Decimal.MinusOne;// print valuesConsole.WriteLine(decimalNumberOne);Console.WriteLine(decimalNumberTwo);Console.WriteLine(decimalNumberThree);}}
Decimal.MinusOne
.Decimal.MinusOne
field as a value.