The number of patterns to match is small, so you can set up a list of regular expressions to capture this. For example, for five digit sequences:
grep -e 12345 -e 23456 […] -e 65432 -e 54321
The number of patterns to match is small, so you can set up a list of regular expressions to capture this. For example, for five digit sequences:
grep -e 12345 -e 23456 […] -e 65432 -e 54321