private void validateInput(String src) {
    if (src == null) {
      throw new IllegalArgumentException("You can't pass a null String as input parameter.");
    }
  }
Tail recursive solution to this problem. The complexity order in time and space terms of this
recursive version is the same than te previous one.
src/main/java/com/github/pedrovgs/problem53/CompressString.java