Regex to match 2 parts of a string to each other

Viewed 22

The scenario that I have is that I want to match 2 parts of the string separated by '\' to each other no matter what value is there. Here are few examples:

  • 10/10: matches
  • 50/50: matches
  • 50/10: doesn't match (since 50 doesn't match 10)

This is the regex I currently have: \d*\/\d* but it doesn't take into consideration the values of these integers.

0 Answers
Related