Skip to content
/ goching Public

goching is a simple I Ching library inspired by the old I Ching Unix command line tool

License

Notifications You must be signed in to change notification settings

flrnd/goching

Repository files navigation

I Ching go

I Ching library written in Go

Example

package main

import (
	"fmt"

	"github.com/flrnd/goching"
)

func print(reading goching.Reading) {
	fmt.Printf("Hexagram: %v\n", reading.Hexagram.Number)
	if len(reading.Lines) > 0 {
		fmt.Print("Lines: ")
		for _, line := range reading.Lines {
			fmt.Printf("%v ", line+1)
		}
		fmt.Println()
		fmt.Printf("Relating: %v\n", reading.Relating.Number)
	}
}

func main() {
	myReading := goching.CastReading(goching.NewStalks())

	print(*myReading)
}

Go Report Card

About

goching is a simple I Ching library inspired by the old I Ching Unix command line tool

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages