-10

I would like build a regular expression for "IN12345678" (i.e., starts with IN and ends with eight digit, totally 10).

Dharman
  • 30,962
  • 25
  • 85
  • 135

2 Answers2

1

The following regex will do what you require ^IN\d{8}$

Dharman
  • 30,962
  • 25
  • 85
  • 135
ajinkya narkar
  • 384
  • 1
  • 4
0

This regex works for your case

/^IN[0-9]{8}$/
Jins Peter
  • 2,368
  • 1
  • 18
  • 37