In a six digit (or larger) number, locate the greatest sequence of five consecutive digits found within the number given.
Example
In the following 10 digit number:
1234567890
67890 is the greatest sequence of 5 consecutive digits.
Tests
digit5(7316717)
digit5(1234567898765)
This challenge comes from jhoffner on CodeWars. Thank you to CodeWars, who has licensed redistribution of this challenge under the 2-Clause BSD License!
Want to propose a challenge idea for a future post? Email yo+challenge@dev.to with your suggestions!