It claims zero or even more event of whitespace characters, accompanied by a comma and afterwards followed by zero or maybe more incidence of whitespace characters. Having said that x.replaceAll("\s+", ""); might be far more productive way of trimming Areas (if string can have many contiguous spaces) for the reason https://mantra-bars-euphoria-bar22197.mdkblog.com/37073911/mantra-mushroom-chocolate-bars-an-overview