We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 40cb68c commit 98996a6Copy full SHA for 98996a6
cmd/trygolang/main.go
@@ -66,6 +66,7 @@ func main() {
66
break
67
}
68
69
+ candidates = make([]string, 0, len(mapping))
70
for k := range mapping {
71
if strings.Contains(k, userInput) {
72
candidates = append(candidates, k)
@@ -78,7 +79,9 @@ func main() {
78
79
fmt.Printf("Not found...Try Again")
80
goto nextinput
81
case numberOfCandidate == 1:
82
+ userInput = candidates[0]
83
if v, ok := mapping[userInput]; ok {
84
+ fmt.Printf("[Name] %q\n", userInput)
85
if err := v(); err != nil {
86
log.Fatal(err)
87
0 commit comments