Skip to content
/ tern Public

TernAry is a simple, lightweight, and easy-to-use function to implement a ternary statement in golang.

License

Notifications You must be signed in to change notification settings

Karim-W/tern

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tern

TernAry is a simple, lightweight, and easy-to-use function to implement a ternary statement.

Usage

package main

import (
    "fmt"
    "github.com/karim-w/tern"
)

func main() {
    a := 1
    b := 2
    fmt.Println(tern.Ary(a > b, a, b))
}

License

BSD 3-Clause License

Author

karim-w

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

About

TernAry is a simple, lightweight, and easy-to-use function to implement a ternary statement in golang.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages