The 's' replaces one Area match at any given time even so the 's+' replaces The entire House sequence directly with the next parameter. On the other hand x.replaceAll("\s+", ""); is going to be a lot more efficient strategy for trimming spaces (if string may have numerous contiguous Areas) since https://jeffreysysle.xzblogs.com/72468628/about-s