finished printAnagramsTogether, sameCharsNDistanceAway and inPlaceStringTransform