본문 바로가기
알고리즘/Codewars

[Codewars] Printing Array elements with Comma delimiters (8 kyu) / JavaScript

by fluss 2023. 4. 4.

https://www.codewars.com/kata/56e2f59fb2ed128081001328

 

Codewars - Achieve mastery through coding practice and developer mentorship

A coding practice website for all programming levels – Join a community of over 3 million developers and improve your coding skills in over 55 programming languages!

www.codewars.com

 

DESCRIPTION:

Input: Array of elements

["h","o","l","a"]

Output: String with comma delimited elements of the array in th same order.

"h,o,l,a"

Note: if this seems too simple for you try the next level

 

코드

function printArray(array){
  return array.join();
}

댓글