all

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type All

type All = bool

type Type

type Type struct {
	monoid.Type[All]
}

func NewType

func NewType() Type
Example
package main

import (
	"fmt"

	"github.com/calebcase/base/data/list"
	"github.com/calebcase/base/data/monoid/all"
)

func main() {
	t := all.NewType()

	fmt.Println(
		t.SAssoc(
			true,
			t.SAssoc(
				t.MEmpty(),
				false,
			),
		),
	)

	fmt.Println(
		t.MConcat(
			list.Map(
				func(x int) bool {
					return x%2 == 0
				},
				list.List[int]{2, 4, 6, 7, 8},
			),
		),
	)

}
Output:

false
false

Jump to

Keyboard shortcuts

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