+ 1
how to print Four decimal digits
i want to print xxx.xxxx not xxx.xxxxxxxxx
2 Réponses
+ 2
Console.WriteL("{0:F4}", yourNumber);
:F4 lets the program know that you want 4 digits after the decimal point (:F5 would mean 5 digits etc)
+ 1
you can also use Math.Round(yourNumber, 4);