mirror of https://github.com/rwxrob/bonzai
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
325 B
Go
20 lines
325 B
Go
// Copyright 2022 Robert S. Muhlestein.
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
package filt_test
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/rwxrob/bonzai/filt"
|
|
)
|
|
|
|
func ExampleHasPrefix() {
|
|
set := []string{
|
|
"one", "two", "three", "four", "five", "six", "seven",
|
|
}
|
|
fmt.Println(filt.HasPrefix(set, "t"))
|
|
// Output:
|
|
// [two three]
|
|
}
|