added tail, join, and head function functionality to strings