package main import ( "fmt" "os" "bufio" "io" "time" ) func main() { file, err := os.Open("test.txt") defer file.Close() if nil == err { buff := bufio.NewReader(file) for { line, err := buff.ReadString(' ') if err == io.EOF { break } fmt.Print(line) time.Sleep(10*time.Millisecond) } } }