grotere buffer voor scanner

This commit is contained in:
Peter Kleiweg
2026-08-04 13:32:12 +02:00
parent 1de42635d0
commit c37c54148e
26 changed files with 44 additions and 6 deletions

View File

@@ -26,6 +26,7 @@ func main() {
counts := make(map[string]int)
scanner := bufio.NewScanner(os.Stdin)
scanner.Buffer(nil, 1000000)
for scanner.Scan() {
word := strings.Split(scanner.Text(), "\t")[0]
counts[word] = counts[word] + 1