util

package
v0.0.0-...-36d9f8f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2019 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadInput

func ReadInput() []string

Types

type Computer

type Computer struct {
	Stdin  chan int64
	Stdout chan int64
	// contains filtered or unexported fields
}

func NewComputer

func NewComputer() *Computer

func (*Computer) Cpy

func (c *Computer) Cpy(src int64, dst string)

func (*Computer) Dec

func (c *Computer) Dec(register string)

func (*Computer) Inc

func (c *Computer) Inc(register string)

func (*Computer) Jnz

func (c *Computer) Jnz(value int64, count int64)

func (*Computer) Mul

func (c *Computer) Mul(x, y int64, dst string)

func (*Computer) Out

func (c *Computer) Out(value int64)

func (*Computer) Run

func (c *Computer) Run(program [][]string)

func (*Computer) SetRegister

func (c *Computer) SetRegister(register string, value int64)

func (*Computer) String

func (c *Computer) String() string

func (*Computer) Tgl

func (c *Computer) Tgl(offset int64)

type Letters

type Letters struct {
	// contains filtered or unexported fields
}

func NewLetters

func NewLetters() *Letters

func (*Letters) Add

func (l *Letters) Add(s string)

func (*Letters) Count

func (l *Letters) Count(key string) int

func (*Letters) Len

func (l *Letters) Len() int

func (*Letters) Less

func (l *Letters) Less(i, j int) bool

func (*Letters) Sorted

func (l *Letters) Sorted() []string

func (*Letters) String

func (l *Letters) String() string

func (*Letters) Swap

func (l *Letters) Swap(i, j int)

type StringWriter

type StringWriter struct {
	// contains filtered or unexported fields
}

func (*StringWriter) String

func (s *StringWriter) String() string

func (*StringWriter) Write

func (s *StringWriter) Write(p string) (int, error)

func (*StringWriter) WriteByte

func (s *StringWriter) WriteByte(b byte) error

func (*StringWriter) Writef

func (s *StringWriter) Writef(format string, args ...interface{})

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL