I used the split command to seperate the name string around the space character.
I think String[] functions similarly to creating a list of strings in python.