Advertisement
Guest User

Untitled

a guest
Aug 17th, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.22 KB | None | 0 0
  1. /**
  2. *
  3. * Comprobar si una cadena es un número hexadecimal usando
  4. * expresiones regulares
  5. * @author parzibyte
  6. * Visita: parzibyte.me
  7. */
  8.  
  9. const esHexadecimal = numeroHexadecimal => /^[0-9A-F]+$/ig.test(numeroHexadecimal);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement