word

package
v0.0.0-...-190ce43 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package word provides functions to count word frequency and length.

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func Count

func Count(s string) int

Count returns the number of words in a string

Example
fmt.Println(Count("one two three"))
Output:

3

func UseCount

func UseCount(s string) map[string]int

UseCount return a map of the counts of each word used in a string

Types

This section is empty.

Jump to

Keyboard shortcuts

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