Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

js check string for pangram

//Detect Pangram
function isPangram(string){
// character set capturing group with negative lookahead
  let regex = /([a-z])(?!.*1)/gi;
  return (string.match(regex)).length === 26;
}

console.log(isPangram("The quick brown fox jumps over the lazy dog."));// true
console.log(isPangram("This is not a pangram."));// false
console.log(isPangram("Pack my box with five dozen liquor jugs."));// true
Comment

PREVIOUS NEXT
Code Example
Javascript :: disable editing ace code edior 
Javascript :: jquery transform scale 
Javascript :: using material ui icons in react 
Javascript :: jquery onclick not working 
Javascript :: Install Vue + Laravel 8 
Javascript :: getting the current url in node js 
Javascript :: javascript search on docuemt for text on iframe 
Javascript :: get discord.js role 
Javascript :: cors error in react 
Javascript :: how to scroll down to the bottom of a div using javascript 
Javascript :: click anywhere and div hide javascript 
Javascript :: delete cr prettier 
Javascript :: jquery get class name 
Javascript :: credit card regex javascript 
Javascript :: datatables cdn file 
Javascript :: javascript random boolean 
Javascript :: nuxt function call top scroll to top 
Javascript :: get select option count using jquery 
Javascript :: how to add comment in react js 
Javascript :: js get object by id from array 
Javascript :: array alphabet 
Javascript :: ajax clear form 
Javascript :: setup ejs views directory in express 
Javascript :: convert to small case in javascript 
Javascript :: javascript check if two date are ugual 
Javascript :: js reverse array loop 
Javascript :: keydown jquery 
Javascript :: Datatables Text Align Center 1 Or More Column 
Javascript :: jquery check if checkbox is not checked 
Javascript :: window onload javascript 
ADD CONTENT
Topic
Content
Source link
Name
3+4 =