I saw that recently this was fix with this bug report
It looks like it failing for me
This is my go code
case c == '\t':
start := time.Now()
partialInput := string(bytes.TrimSpace(inputBuffer))
cmds := cmdContainer.CmdTrie.GetCmds(partialInput)
if len(cmds) > 0 {
autoCompleted := fmt.Sprintf("%s ", cmds[0][1:])
if autoCompleted != " " {
fmt.Fprintf(os.Stdin, autoCompleted)
inputBuffer = append(inputBuffer, []byte(autoCompleted)...)
} else {
// time.Sleep(1 * time.Millisecond)
fmt.Fprintf(os.Stdout, "%c", '\x07')
end := time.Now()
fmt.Fprint(os.Stdout, "\r\nBell took nanos: ", end.Sub(start).Nanoseconds())
}
}
and this is the output
/your_program.sh
$ xyz
Bell took nanos: 48237
mine takes less than a millisecond, in the thread above it looks like the test was timing out at 50ms
any help is appreciated
this is my repo link : https://git.codecrafters.io/40b24cd4c4446918
thanks

