packages/library/odin-money
o

odin-money

af77ffblibrary

No description provided.

0 stars0 forksMITupdated 8 months ago
Open repo

Money (WIP)

Odin money provides ability to work with monetary value using a currency's smallest unit. This package provides basic and precise Money operations such as rounding, splitting and allocating. Monetary values should not be stored as floats due to small rounding differences.

Inspirations are from go-money to practice Odin. i'm still having a hard time understanding memory management

package main 

import "core:fmt"
import "collections:money"

main :: proc(){
    m1 := money.Money{100, money.USD}
    m2 := money.Money{100, money.USD}
    m1 = money.add(m1,m2)
    fmt.printfln("$100 + $100 = %v", m1)
}
Package Info
Version
af77ffb
License
MIT
Author
@gray-adeyi
Type
library
Forks
0
Created
8 months ago
Updated
8 months ago
Health
maintained
has releases
has readme
has license
Activity
last 56 weeks