Skip to document

C# Math - C# notes

C# notes
Course

Programming 1 (CS101)

40 Documents
Students shared 40 documents in this course
Academic year: 2022/2023
Uploaded by:
0followers
2Uploads
0upvotes

Comments

Please sign in or register to post comments.

Preview text

❮ Previous Next ❯ Coursary Search for courses for free

C# Math

The C# Math class has many methods that allows you to perform mathematical tasks on numbers.

Math(x,y)

The Math( x, y) method can be used to find the highest value of x and y:

Example

Math( 5 , 10 ); Try it Yourself »

Math(x,y)

The Math( x, y) method can be used to find the lowest value of of x and y:

  HTML CSS   

 Menu  Log in

Example

Math( 5 , 10 ); Try it Yourself »

Math(x)

The Math( x) method returns the square root of x:

Example

Math( 64 ); Try it Yourself »

Math(x)

The Math( x) method returns the absolute (positive) value of x:

Example

Math(-4); Try it Yourself »

❮ Previous Next ❯ Compare courses from top universities and online platforms for free. OPEN Create your own website with W3schools Spaces Get started

####### COLOR PICKER

####### LIKE US

Get certified by completing a course today!

  

w 3 s choo l s C E R T I F IED. 20 2 1 Get started

####### CODE GAME

Play Game

JavaScript Reference SQL Reference Python Reference W3 Reference Bootstrap Reference PHP Reference HTML Colors Java Reference Angular Reference jQuery Reference

####### Top Examples

HTML Examples CSS Examples JavaScript Examples How To Examples SQL Examples Python Examples W3 Examples Bootstrap Examples PHP Examples Java Examples XML Examples jQuery Examples

####### Web Courses

HTML Course CSS Course JavaScript Course Front End Course SQL Course Python Course PHP Course jQuery Course Java Course C++ Course C# Course XML Course Get Certified » W3Schools is optimized for learning and training. Examples might be simplified to improve reading and learning. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. While using W3Schools, you agree to have read and accepted our terms of use, cookie and privacy policy. Copyright 1999-2021 by Refsnes Data. All Rights Reserved. W3Schools is Powered by W3.

Was this document helpful?

C# Math - C# notes

Course: Programming 1 (CS101)

40 Documents
Students shared 40 documents in this course

University: Kabul University

Was this document helpful?
Previous
Next
Coursary
Search for courses for free
C# Math
The C# Math class has many methods that allows you to perform mathematical tasks on
numbers.
Math.Max(x,y)
The Math.Max(
x
,
y
) method can be used to find the highest value of x and y:
Example
Math.Max(5, 10);
Try it Yourself »
Math.Min(x,y)
The Math.Min(
x
,
y
) method can be used to find the lowest value of of x and y:
HTML CSS
Menu
Log in