Calculates the checksum of an given ean string.
See https://en.wikipedia.org/wiki/International_Article_Number_(EAN)
returns integer from 0, 9. -1 if the input String is not a string of all digits.
A string of digits