I believe I have found an error in the read_fwf documentation here https://readr.tidyverse.org/reference/read_fwf.html
I hope this is the place to report it. Please delete if I'm wrong.
The documentation says:
#> # A tibble: 3 x 3
#> name state ssn
#> <chr> <chr> <chr>
#> 1 John Smith WA 418-Y11-4111
#> 2 Mary Hartford CA 319-Z19-4341
#> 3 Evan Nolan IL 219-532-c301
# 3. Paired vectors of start and end positions
read_fwf(fwf_sample, fwf_positions(c(1, 30), c(10, 42), c("name", "ssn")))
#> Parsed with column specification:
#> cols(
#> name = col_character(),
#> ssn = col_character()
#> )
But I believe the eighth line should read:
read_fwf(fwf_sample, fwf_positions(c(1,10), c(30,42), c("name", "ssn")))