
Question on Convert.ChangeType
From Microsoft's documentation, https://learn.microsoft.com/en-us/dotnet/api/system.convert.changetype?view=net-10.0 it seems like "Convert.ChangeType(double number, typeof(int))" would return an int. However I see that in reality, the result has to still be explicitly cast afterwards like (int)Convert.ChangeType(double number, typeof(int))". From what I understand, Convert.ChangeType is changing a double to the base "object" class in the example above, and then that object still has to be converted (via the cast) to the int. So why does it require the conversiontype as an argument then? Confusing!