Well the first part of output in the first line is the start index of the pattern.As you know the index starts from 0 so it starts its searches from 0 and the first digit it encounters is 5 and then it should be followed by
word character which could be [a-zA-Z0-9_] so 56 is the first
pattern that matches adn the index of 5 is 4 hence the output is 4 starting position and the matched
string 56.
4 inthe output is not the 4 from the input String.
Hope it helps