Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

125
Views
Usando? = en la expresión regular de javascript

en javascript

 console.log(/x(?=b[1-9])/.test('xb2')); // true console.log(/x(?=b[1-9])$/.test('xb2')); // false

cual es la diferencia

about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

El primer patrón x(?=b[1-9]) coincide con x , seguido de b y un dígito. La entrada xb2 coincide con esto.

El segundo patrón x(?=b[1-9])$ está en conflicto y nunca puede coincidir con nada. Este patrón dice que coincida:

 x the letter x (?=b[1-9]) assert that b and 1-9 follows $ match end of the input

Es imposible que b[1-9] siga a x mientras que al mismo tiempo x es el final de la entrada. Use la primera versión en su pregunta.

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!