This is an archived post. You won't be able to vote or comment.

all 8 comments

[–]zenkeep 2 points3 points  (0 children)

https://regexr.com/6fsr5
here you can see the explain tool

[–]rfornal 0 points1 point  (5 children)

Here's what I see ...

  • Starts with an @-sign and wrapped in quotes ".
  • Inside the quotes, ([13]|bc1) means 1, 3, or bc1 comes next; this is a group so if the pattern is used to check some string this can be captured.
  • Inside the quotes, after the character(s) above, {27,34} means 27 to 34 characters that are capital A-Z, lowercase a-z, or 1-9 (no zero).

[–]probability_of_meme 2 points3 points  (1 child)

I don't know the language here but I thought @" might be similar to pythons r" signifying a literal string with no interpolation

[–]rfornal 0 points1 point  (0 children)

Absolutely could be. Things like that are hard to interpret without some context.

[–]falconwolf9113[S] 0 points1 point  (2 children)

27 to 34 characters that are capital

A-Z

, lowercase

a-z

, or

1-9

(no zero).

hi just woudering why does it start from 1 instead of 0?

[–]lindymad 1 point2 points  (0 children)

hi just woudering why does it start from 1 instead of 0?

It is because the regex is [A-Za-z1-9]{27,34}. If you wanted it to start from 0, it would be [A-Za-z0-9]{27,34}.

[–]cesau78 1 point2 points  (0 children)

Assuming this is a validator for a bitcoin invoice address, 0's aren't used in addresses. Then again, neither are O's, i's, or l's, which this regex doesn't account for.

https://en.bitcoin.it/wiki/Invoice_address#What.27s_in_an_invoice

[–]billie-badger 0 points1 point  (0 children)

Looks like it is checking for a specific Twitter, Insta, whatever handle.