text layout: edge case
text layout: edge case: a task in smol-software-harbor (Harbor dataset). Wrap in wrap/wrap.go gets two edge cases wrong: a line that would be exactly width characters long is broken too early, and several spaces in a row (or leading / trailing spaces) produce empty "words", hence doubled spaces…
The task
`Wrap` in `wrap/wrap.go` gets two edge cases wrong: a line that would be exactly `width` characters long is broken too early, and several spaces in a row (or leading / trailing spaces) produce empty "words", hence doubled spaces and empty lines. Words are separated by any run of whitespace. Fix `Wrap` and run `go…
Part of efederici/smol-software-harbor.