summaryrefslogtreecommitdiff
path: root/radix_info.go
blob: 04a8228134c5b2114c963a378c5ef98e9c1ca3d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package main

import (
	"fmt"
	"os"
)

func main() {
	args, err := parseArgs()
	if err == nil {
		factorInfo := GetFactorInfo(args.Radix)
		if args.Compact {
			factorInfo.WriteToCompact(os.Stdout)
		} else {
			factorInfo.WriteTo(os.Stdout)
		}
	} else {
		fmt.Fprintln(os.Stderr, err)
	}
}