All pastes #12821 Raw Edit

Something

public text v1 · immutable
#12821 ·published 2005-05-28 01:08 UTC
rendered paste body
using System;

class Testing
{
	static void Main()
	{
		double foo = 25.642;
		What( foo );
		What( (int)foo );
	}
	static void What( System.Object argument )
	{
		System.Object bar = (Object)argument;
		Console.WriteLine( "\t{0}: {1}", argument.GetType(), argument );
		Console.WriteLine("\t{0}: {1}", bar.GetType(), bar );
	}
}

/* output:

Administrator@Amnesiac>mcs test.cs
Administrator@Amnesiac>./test.exe
        System.Double: 25.642
        System.Double: 25.642
        System.Int32: 25
        System.Int32: 25
Administrator@Amnesiac>
*/