The 's' replaces 1 space match at any given time even so the 's+' replaces the whole House sequence simultaneously with the 2nd parameter. On the other hand x.replaceAll("\s+", ""); might be far more effective way of trimming Areas (if string can have many contiguous spaces) for the reason that https://mantra-bars-euphoria-bar99763.activoblog.com/32795131/the-definitive-guide-to-mantra-euphoria-gummie