We start at 0 for substring and almost all the formulas except length() where we actually count(start at 1).
String's characters start at 0. An example would be: 0 = H 1 = e 2 = l 3 = l 4 = o