fork download
  1. using System;
  2. using System.Globalization;
  3.  
  4. public class Test
  5. {
  6. public static void Main()
  7. {
  8. CultureInfo formato = null;
  9. formato = (CultureInfo)CultureInfo.InvariantCulture.Clone();
  10. formato.NumberFormat.NumberDecimalSeparator = ".";
  11. formato.NumberFormat.NumberGroupSeparator = ",";
  12.  
  13. string x = "19.30";
  14. System.Console.Write(Convert.ToDouble(x, formato));
  15. }
  16. }
Success #stdin #stdout 0.04s 34784KB
stdin
Standard input is empty
stdout
19.3