You probably wondered how typing words that corresponded to my hints relates to JavaScript. Well actually, you just did some RegExp (short for regular expressions), but in English. Using RegExp, you can match a string to a combination of characters. You can match numbers, letters, spaces, specific characters, etc. RegExp is useful mainly for form validation. RegExp is rather hard to grasp (and you will likely forget the syntax quickly), but when you translate it to English it isn't so hard to understand. And yes it looks like gibberish. For example, an email validation RegExp would look like:
/^[-a-z0-9~!$%^&*_=+}{\'?]+(\.[-a-z0-9~!$%^&*_=+}{\'?]+)*@([a-z0-9_][-a-z0-9_]*(\.[-a-z0-9_]+)*\.(aero|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|mobi|[a-z][a-z])|([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))(:[0-9]{1,5})?$/i
See the below links for learning about RegExp:
To match strings with RegExp:
var regexp = new RegExp(/\w+\d{5}0/, "i");
var string = "hello123450";
regexp.test(string);//this will equal true if the RegExp matches the string, which it does