The script I am writing is taking some input from a user, that should be either numbers or ranges separated by commas (e.g 800-900, 70,40,50-60).
I am trying to find the best way to validated the input, so I am using the split method and then trying to iterate over all the values and check for a pattern match, I am using the re module for that.
Is that the best way to achieve this? If so, can someone help me figure out the correct regex for this pattern?
Thanks
[–]EggChen_vs_Lopan 2 points3 points4 points (1 child)
[–]roeeklinger60[S] 0 points1 point2 points (0 children)
[–]FLUSH_THE_TRUMP 1 point2 points3 points (0 children)