https://github.com/ryanavella/wide
Uint128 and Int128 for Go
https://github.com/ryanavella/wide
go golang int128 integer integers uint128
Last synced: 10 months ago
JSON representation
Uint128 and Int128 for Go
- Host: GitHub
- URL: https://github.com/ryanavella/wide
- Owner: ryanavella
- License: mit
- Created: 2018-11-03T22:02:05.000Z (over 7 years ago)
- Default Branch: develop
- Last Pushed: 2019-07-09T03:21:01.000Z (over 6 years ago)
- Last Synced: 2025-04-06T02:11:47.251Z (11 months ago)
- Topics: go, golang, int128, integer, integers, uint128
- Language: Go
- Homepage:
- Size: 31.3 KB
- Stars: 4
- Watchers: 2
- Forks: 3
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE-MIT
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
[](https://godoc.org/github.com/ryanavella/wide) [](https://goreportcard.com/report/github.com/ryanavella/wide) [](https://github.com/ryanavella/wide/blob/develop/LICENSE-MIT) [](https://github.com/ryanavella/wide/blob/develop/LICENSE-UNLICENSE)
# Wide
Uint128 and Int128 for Go.
Wide is free and open source software distributed under the terms of both the MIT License and the Unlicense.
## Installing
```shell
go get github.com/ryanavella/wide
```
## Usage
```golang
package main
import (
"fmt"
"github.com/ryanavella/wide"
)
func main() {
a := wide.Int128FromInt64(-3)
b := wide.Int128FromInt64(2)
fmt.Println(a, b, a.Add(b), a.Sub(b), a.Mul(b), a.Div(b), a.Mod(b))
}
```
## Scope
This package is intended for efficient and fast computations (i.e. for scientific and mathematical applications). There are no plans to support applications which require constant-time cryptographic security.
## Contributions
See [contributor guidelines](CONTRIBUTING.md).