There are two things in regexp you need to consider:
Just like in any text editor cursor might be positioned just before the character or just after - never on the character itself. If cursor progresses forward it “eats” character checking the pattern.
Look aheads are instructions that tell regexp (cursor) to “look ahead” from it’s current position (index). So two instructions provided in your example can be translated in English like so:
- Without eating characters, look ahead and see if there are from 3 to 6 alphanumeric characters
- Without eating characters, look ahead and see if there is any digit
\d followed by 0 or more non-digit characters.
Note that there is no specification of any particular position of these characters or digits, which makes this rule very loose.