Created
December 10, 2019 11:56
-
-
Save Paul-Browne/25f6368a92770b8790c966450d698764 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var weekdays = ["Monday", "Tuesday", "Wednesday", "Thursday", "Friday"]; | |
var eg1 = weekdays.join(); | |
var eg2 = weekdays.join(""); | |
var eg3 = weekdays.join(" + "); | |
console.log(eg1); | |
// "Monday,Tuesday,Wednesday,Thursday,Friday" | |
console.log(eg2); | |
// "MondayTuesdayWednesdayThursdayFriday" | |
console.log(eg3); | |
// "Monday + Tuesday + Wednesday + Thursday + Friday" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment