fork download
  1. Input <- "I ES P E ES P 010 000 000 000 000 000 001 001 000 000 IESP 000 000"
  2. gsub("(?<=[A-Z])\\s+(?=[A-Z])", "", Input, perl=TRUE, ignore.case = TRUE)
Success #stdin #stdout 0.16s 175424KB
stdin
Standard input is empty
stdout
[1] "IESPEESP 010 000 000 000 000 000 001 001 000 000 IESP 000 000"