Skip to content

Commit

Permalink
Doubles max buffer size for bufio.Scanner
Browse files Browse the repository at this point in the history
  • Loading branch information
tomnomnom committed Jul 19, 2022
1 parent c065828 commit e5ae317
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ func main() {
}

sc := bufio.NewScanner(os.Stdin)
buf := make([]byte, 0, 64*1024)
sc.Buffer(buf, 128*1024)

seen := make(map[string]bool)

Expand Down

0 comments on commit e5ae317

Please sign in to comment.