string split by space code example
Example 1: javascript string to array
const str = 'Hello!';
const arr = Array.from(str);
//[ 'H', 'e', 'l', 'l', 'o', '!' ]
Example 2: space seperator in string in java
String[] splitted = "peter,james,thomas".split(",");