Slightly shortened the string function