Hey guys, I did this /Hello, World[^\s$]/; and it passes the test check but the answer from FCC is: ```
let wsRegex = /^\s+|\s+$/g;
I would like to know if it's okay to answer this question the way I did, or if I should switch to the answer given by FCC. And if possible, can I get an explanation as to why? Thank you so much, any help is appreciated! **Your code so far** ```js let hello = " Hello, World! "; let wsRegex = /Hello, World[^\s$]/; // Change this line let result = hello.match(wsRegex); // Change this line console.log(result)
Your browser information:
User Agent is:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36.