Regular Expression

 g -- global

i -- case sensetive

+ -- atleast one

? -- optional

*  --- zero or more 

.at   --- matches any word that ending or contains  at





g -- global

Examples 



i -- case sensitive






a+  ---  atleast matching one and proceeding token

example


matching words that contains atleast one  e


matching words that contains one e and proceeding token at



matching words that has e and a is optional



matching words that has 

e -- compulsory

e-- optional

t -- compulsory



matching words that has 

e -- compulsory

e-- optional

t -- optional



matching words that has 

e -- compulsory

a-- atleast one a

t -- optional




it matching that word has letter  e and r is optional




.at   --- matches any word that ending or contains  at


\w   -- matches all the word








\W  matches  except words




\s  matches white space



matching all words that contain more than 7 letters




matching words that has and contains any of the these letter [Slt]






matching words that has any word from a to z and ending with a


matching the word either T or t 


^  staring line
m  for multiline



Comments

Popular posts from this blog

TimeConversion in 24 hour format

minimum and maximum values that can be calculated

calculate the absolute difference between the sums of its diagonals.