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

157
Views
Construyendo una expresión regular muy simple

Necesito hacer coincidir "-" o "_" seguido de un carácter alfabético (AZ,az). Entonces, por ejemplo, para "simple-hello_world-" necesito hacer coincidir "-h" y "_w".

Esta es mi expresión regular: /-|_[AZ]/i

Pero parece que [AZ] es una coincidencia opcional porque coincide si la cadena termina con un "-" o con un "_":

 "hellogworld-".match(/-|_[AZ]/i)

[ '-', indefinido, índice: 11, entrada: 'hellogworld-', grupos: indefinido]

Cualquier ayuda es apreciada.

about 4 years ago · Juan Pablo Isaza
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!