package
module
Version:
v0.0.0-...-6f5d426
Opens a new window with list of versions in this module.
Published: Oct 15, 2022
License: MIT
Opens a new window with license information.
Imports: 1
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
Luhn Formula is a go module that uses the luhn aglorithm also known as Modulus 10 Algorithm to verify if a number is a luhn number
Usage
To get:
go get github.com/gospacedev/luhn-formula
You can use it as:
package main
import (
"fmt"
"github.com/gospacedev/luhn-formula"
)
func main() {
a := luhn.Check("79927398713")
b := luhn.Check("1111")
fmt.Println(a)
fmt.Println(b)
}
The output will be:
true
false
Documentation
¶
Checks if the string is a luhn number
Source Files
¶
Directories
¶
Click to show internal directories.
Click to hide internal directories.