The 's' replaces one particular Room match at any given time although the 's+' replaces The entire space sequence directly with the second parameter. However x.replaceAll("\s+", ""); will be additional productive method of trimming Areas (if string can have many contiguous spaces) mainly because of potentially less no of replacements https://mantra-euphoria-gummies86429.link4blogs.com/53035391/s-an-overview