Essential Types C# Book

using System;
using System.Text;
using System.Globalization;
class Sample
{
public static void Main()
{
double d = 3.9;
int i = Convert.ToInt32(d);
Console.WriteLine(i);
}
}
The output:
4