February 2018
Intermediate to advanced
340 pages
9h 43m
English
123.Jun.......Wong...... 12..Novak.....Jurgen.... 10..Thomas....Sohlich...
package main import ( "errors" "fmt" "os" ) const lineLegth = 25 func main() { f, e := os.OpenFile("flatfile.txt", os.O_RDWR|os.O_CREATE, os.ModePerm) if e != nil { panic(e) } defer f.Close() fmt.Println(readRecords(2, "last", f)) if err := writeRecord(2, "first", "Radomir", f); err != nil { panic(err) } fmt.Println(readRecords(2, "first", f)) if err := writeRecord(10, "first", "Andrew", f); err != nil { panic(err) } fmt.Println(readRecords(10, "first", ...Read now
Unlock full access