I have an array that contains data, so it'll be like:
array(27.42, 27.71, 26.61, 204.12 1995-1-17)
And I want to remove all words with dashes so that I'm left with an array that looks like:
array(27.42, 27.71, 26.61, 204.12)
Here's a picture of the exact array.
https://i.stack.imgur.com/KRPDt.png
Do I use regex? What is the best method. I tried using an if function to replace all words that include "-" with " ", but it didn't work.
Any help is much appreciated!