fork download
  1. using static System.Console;
  2.  
  3. public class Program {
  4. public static void Main() {
  5. WriteLine(decimal.Multiply(50.40M, 3));
  6. WriteLine(50.40M * 3);
  7. // WriteLine(decimal.Multiply(50.40, 3));
  8. WriteLine(50.40 * 3);
  9. WriteLine(decimal.Multiply(50, 3).GetType());
  10. WriteLine((50 * 3).GetType());
  11. // decimal x = 1_000_000 * 1_000_000;
  12. decimal x = decimal.Multiply(1_000_000, 1_000_000);
  13. }
  14. }
  15.  
  16. //https://pt.stackoverflow.com/q/364116/101
Success #stdin #stdout 0.02s 16264KB
stdin
Standard input is empty
stdout
151.20
151.20
151.2
System.Decimal
System.Int32