Simplified random string funcion