8 kyu

CSV representation of array

10,575 of 19,711Dmitry Kudla

Description:

Create a function that returns the CSV representation of a two-dimensional numeric array.

Example:

input:
   [[ 0, 1, 2, 3, 4 ],
    [ 10,11,12,13,14 ],
    [ 20,21,22,23,24 ],
    [ 30,31,32,33,34 ]] 
    
output:
     '0,1,2,3,4\n'
    +'10,11,12,13,14\n'
    +'20,21,22,23,24\n'
    +'30,31,32,33,34'

Array's length > 2.

More details here: https://en.wikipedia.org/wiki/Comma-separated_values

Note: you shouldn't escape the \n, it should work as a new line.

Fundamentals
Arrays
Strings

Stats:

CreatedDec 16, 2017
PublishedDec 16, 2017
Warriors Trained32285
Total Skips1420
Total Code Submissions50431
Total Times Completed19711
JavaScript Completions10575
Python Completions6101
Ruby Completions361
C Completions195
C# Completions666
D Completions12
Go Completions766
Rust Completions376
TypeScript Completions459
PHP Completions384
Scala Completions32
CoffeeScript Completions11
Java Completions603
Julia Completions7
Prolog Completions5
Total Stars346
% of votes with a positive feedback rating91% of 2303
Total "Very Satisfied" Votes1942
Total "Somewhat Satisfied" Votes297
Total "Not Satisfied" Votes64
Total Rank Assessments3
Average Assessed Rank
7 kyu
Highest Assessed Rank
7 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • Dmitry Kudla Avatar
  • raulbc777 Avatar
  • Chrono79 Avatar
  • ltison Avatar
  • Madjosz Avatar
  • jamad Avatar
  • drexduarte Avatar
  • a.kozhanov Avatar
  • hobovsky Avatar
  • stellartux Avatar
  • ejini战神 Avatar
  • akar-0 Avatar
  • meni181818 Avatar
  • MingLeeNg Avatar
  • KayleighWasTaken Avatar
Ad