1var regex = /\d+/g;
2var string = "Any string you want!";
3var matches = string.match(regex); // creates array from matches45if (matches){
6// There is a digit in the string.7} else {
8// No Digits found in the string.9}
you will get a confirmation link on this - you will have to click that for successful submission of your answer. we require this to keep the website free of spam, bots and unhelpful content
please ensure to add code which is syntactically corrent and executes properly
you will get a confirmation link on this - you will have to click that for successful submission of your question. we require this to keep the website free of spam, bots and unhelpful content