MathF.Pow() Method in C# with Examples Last Updated : 04 Apr, 2019 Summarize Comments Improve Suggest changes Share Like Article Like Report In C#, MathF.Pow(Single, Single) is a MathF class method. This method is used to calculate a number raise to the power of some other number. Syntax: public static float Pow (float x, float y); Parameters: x: It is a single-precision floating-point number which is to be raised to a power and type of this parameter is System.Single. y: It is a single-precision floating-point number which specifies a power or exponent and type of this parameter is System.Single. Return Type: The function returns the number base raised to the power. The return type of this method is System.Single Example: CSHARP // C# program to illustrate the // MathF.Pow(Single, Single) Method using System; class GFG { // Main Method static public void Main() { // Find power using MathF.Pow // 8 is base and 4 is power or // index or exponent of a number float pow_ab = MathF.Pow(8f, 4f); // Print the result Console.WriteLine(pow_ab); // 7.5 is base and 2 is power or // index or exponent of a number float pow_tt = MathF.Pow(7.5f, 2f); // Print the result Console.WriteLine(pow_tt); // 1234 is base and 7 is power or // index or exponent of a number float pow_t = MathF.Pow(1234f, 7f); // Print the result Console.WriteLine(pow_t); } } Output: 4096 56.25 4.357186E+21 Comment More infoAdvertise with us Next Article MathF.Pow() Method in C# with Examples K Kirti_Mangal Follow Improve Article Tags : C# CSharp-method CSharp-MathF-Class Similar Reads MathF.Sqrt() Method in C# with Examples In C#, MathF.Sqrt(Single) is a MathF class(present in system namespace) method which is used to calculate the square root of the specified Single or float data type value. Syntax: public static float Sqrt (float x); Here, x is the number whose square root is to be calculated and type of this paramet 2 min read MathF.Exp() Method in C# with Examples In C#, Exp(Single) is a MathF class method which is used to return the e raised to the specified power. Here e is a mathematical constant whose value is approximately 2.71828. Syntax: public static float Exp (float x); Here, x is the required number of type System.Single which specifies a power. Ret 1 min read MathF.Log() Method in C# with Examples In C#, MathF.Log() is a MathF class method. It is used to return the logarithm of a specified number. This method can be overloaded by changing the number of the arguments passed. There are total 2 methods in the overload list of the MathF.Log() method as follows: MathF.Log(Single) Method MathF.Log( 4 min read MathF.Cbrt() Method in C# with Examples MathF.Cbrt(Single) Method is used to return the cube root of a floating point value. Syntax: public static float Cbrt (float x); Here, it takes a standard floating point number. Return Value: This method returns the cube root of the given value. Example 1: csharp // C# program to demonstrate the // 2 min read MathF.Log10() Method in C# with Examples In C#, MathF.Log10(Single) is a MathF class method. It is used to return the base 10 logarithm of a specified number. Syntax: public static float Log10 (float x); Here, x is the specified number whose logarithm to be calculated and its type is System.Single. Return Value: It returns the logarithm of 2 min read Like