1
0
mirror of https://github.com/duke-git/lancet.git synced 2026-02-23 13:52:26 +08:00

fix: fix go report validation issue

This commit is contained in:
dudaodong
2023-06-01 11:49:49 +08:00
parent b787e99528
commit 286a187942
2 changed files with 3 additions and 7 deletions

View File

@@ -416,22 +416,19 @@ func ExampleWordCount() {
result1 := WordCount("a word") result1 := WordCount("a word")
result2 := WordCount("I'am a programmer") result2 := WordCount("I'am a programmer")
result3 := WordCount("Bonjour, je suis programmeur") result3 := WordCount("a -b-c' 'd'e")
result4 := WordCount("a -b-c' 'd'e") result4 := WordCount("你好,我是一名码农")
result5 := WordCount("你好,我是一名码农") result5 := WordCount("こんにちは,私はプログラマーです")
result6 := WordCount("こんにちは,私はプログラマーです")
fmt.Println(result1) fmt.Println(result1)
fmt.Println(result2) fmt.Println(result2)
fmt.Println(result3) fmt.Println(result3)
fmt.Println(result4) fmt.Println(result4)
fmt.Println(result5) fmt.Println(result5)
fmt.Println(result6)
// Output: // Output:
// 2 // 2
// 3 // 3
// 4
// 3 // 3
// 0 // 0
// 0 // 0

View File

@@ -112,7 +112,6 @@ func ContainLetter(str string) bool {
return letterRegexMatcher.MatchString(str) return letterRegexMatcher.MatchString(str)
} }
// ContainLetter check if the string contain at least one number. // ContainLetter check if the string contain at least one number.
func ContainNumber(input string) bool { func ContainNumber(input string) bool {
return numberRegexMatcher.MatchString(input) return numberRegexMatcher.MatchString(input)