gotrain

package module
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package gotrain is a training package that helps teach how to set up GO packages.

It includes one function Add that adds two integers together.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add[T Number](x1, x2 T) T

Add preforms additon on two integers and returns the result.

Types

type Number

type Number interface {
	constraints.Integer | constraints.Float
}

Number represents either an integer or a floating point number.

Jump to

Keyboard shortcuts

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