digits made of digits. Look for every spot where the same digit appears three times in a row, and return the largest such triple as a three-character string, for example "777".
Triples are compared as numbers, and "000" is allowed. If there is no triple at all, return the empty string "".digits="5222915558" → '555'
Both "222" and "555" fit; the larger one is "555".
digits="70004" → '000'
The only triple is "000". Leading zeros are fine.
digits="1122334" → ''
No digit appears three times in a row, so the answer is empty.
digits contains only digitsdigits="5222915558"
'555'
Run checks the first 3 tests in your browser. Submit checks all 136 tests on the server, hidden ones included.