Skip to content
This repository has been archived by the owner on Jul 21, 2024. It is now read-only.

Commit

Permalink
Added the possibility to get the opposite of a number (#287)
Browse files Browse the repository at this point in the history
  • Loading branch information
lpeyr committed Jan 8, 2022
1 parent 43cae4a commit 87b50c2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions LeoCorpLibrary/Maths.cs
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,8 @@ public static double DegreesToRadians(double degrees)
/// <returns>A <see cref="bool"/> value.</returns>
public static bool IsInteger(double number) => (double)(int)number == number;

public static double GetOpposite(double n) => 0 - n;

/// <summary>
/// Class that coontains methods for circles.
/// </summary>
Expand Down

0 comments on commit 87b50c2

Please # to comment.