How To Cast Numeric Numbers To Decimal Value Using Suffix In C#
Usually, i do decimal.parse(numeric value) to parse numbers to decimal. But there's a shortcut way to do this. Just append a suffix m or M to the numeric value.
Source: MSDN
decimal balanceBank = 50000.5m; decimal balanceBank = 50000.5M;
Comments
Post a Comment