mathy

package
v0.0.0-...-3cdea5b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 13, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbsInt

func AbsInt(in int) int

func GeneratePrimes

func GeneratePrimes(primes []int, n int) int

GeneratePrimes returns the n-th prime number its param primes []int is intended to contain previously found prime numbers to reduce duplicated work, but still be testable

func MakeRange

func MakeRange(min, max int) []int

func ManhattanDistance

func ManhattanDistance(x1, y1, x2, y2 int) int

func MaxInt

func MaxInt(nums ...int) int

func MinInt

func MinInt(nums ...int) int

func MultiplyIntSlice

func MultiplyIntSlice(nums []int) int

func PythagoreanDistance

func PythagoreanDistance(x1, y1, x2, y2 int) float64

func Reverse

func Reverse(s string) (result string)

func Sum

func Sum(arr []any) int

func SumIntSlice

func SumIntSlice(nums []int) int

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL