A developer has created a string array variable as shown below:
UserNames = {“Jane”, “Jack”, “Jill”, “John”}
Which expression should the developer use in a Log Message activity to print the elements of the array separated by the string “,”?
A developer has created a string array variable as shown below:
UserNames = {“Jane”, “Jack”, “Jill”, “John”}
Which expression should the developer use in a Log Message activity to print the elements of the array separated by the string “,”?
To print the elements of a string array separated by a specific delimiter, the String.Join method is used. This method combines elements of the array into a single string, inserting the specified delimiter between each element. Therefore, using String.Join(',', UserNames) will correctly concatenate the elements of the UserNames array with a comma between each name.
The answer is A, Tried and tested in Studio.