• Log in or sign up for an account here: https://www.sythe.org/login

[Global] Reported Post by Terrankiller

Status
Not open for further replies.

Terrankiller

Ex-Administrator

Retired Administrator
Visual Basic Programmers
Joined
May 7, 2005
Sythe Gold
1
Messages
1,286
Location
California
Terrankiller has reported a post.

Reason:
Advertisement.
Post: cegonsoft chennai | Advance Math in C# .net
Forum: C#
Assigned Moderators: N/A

Posted by: ravbop1
Original Content:
In the past, every language has had its own set of keywords for common math operations such
as rounding and trigonometry. In .NET languages, many of these keywords remain. However,
you can also use a centralized Math class that’s part of the .NET Framework. This has the
pleasant side effect of ensuring that the code you use to perform mathematical operations
can easily be translated into equivalent statements in any .NET language with minimal fuss.
To use the math operations, you invoke the methods of the System.Math class. These
methods are static, which means they are always available and ready to use.

The following code shows some sample calculations that you can perform with the Math class:

double myValue;
myValue = Math.Sqrt(81); // myValue = 9.0
myValue = Math.Round(42.889, 2); // myValue = 42.89
myValue = Math.Abs(-10); // myValue = 10.0
myValue = Math.Log(24.212); // myValue = 3.18.. (and so on)
myValue = Math.PI; // myValue = 3.14.. (and so on)


The features of the Math class are too numerous to list here in their entirety. The previous
examples show some common numeric operations.

Visit: Cegonsoft
 
Status
Not open for further replies.
Runescape Gamblingrunescape gambling
Back
Top