I was just surfing some coding problems in C#. fiddle link here
Q: What is the output of the following code?
using System;
public class Program
{
public static void Main()
{
Console.WriteLine(Math.Round(6.5));
Console.WriteLine(Math.Round(11.5));
}
}
6 12
This is the output.
My doubt is if 6.5 comes as 6. How come 11.5 as 12?
It should be 11 or either 6.5 should be 7.
Maybe it is very unwise, Any suggestion/explanation helps me to understand clearly.