6 kyu
Create Phone Number
127,414 of 350,958xDranik
Description:
Write a function that accepts an array of 10 integers (between 0 and 9), that returns a string of those numbers in the form of a phone number.
Example
createPhoneNumber([1, 2, 3, 4, 5, 6, 7, 8, 9, 0]) // => returns "(123) 456-7890"
The returned format must be correct in order to complete this challenge.
Don't forget the space after the closing parentheses!
Arrays
Strings
Regular Expressions
Algorithms
Similar Kata:
Stats:
Created | Oct 17, 2013 |
Published | Oct 17, 2013 |
Warriors Trained | 596964 |
Total Skips | 48084 |
Total Code Submissions | 808693 |
Total Times Completed | 350958 |
JavaScript Completions | 127414 |
CoffeeScript Completions | 334 |
Ruby Completions | 9142 |
Java Completions | 39656 |
Dart Completions | 2107 |
Haskell Completions | 1813 |
C# Completions | 22755 |
Python Completions | 115677 |
Scala Completions | 967 |
Groovy Completions | 157 |
Crystal Completions | 67 |
PowerShell Completions | 316 |
Go Completions | 4589 |
C Completions | 4539 |
NASM Completions | 63 |
Rust Completions | 3274 |
PHP Completions | 6642 |
Clojure Completions | 408 |
C++ Completions | 14218 |
Julia Completions | 170 |
CFML Completions | 43 |
Factor Completions | 20 |
F# Completions | 99 |
COBOL Completions | 38 |
Lua Completions | 333 |
TypeScript Completions | 4220 |
BF Completions | 52 |
Total Stars | 3755 |
% of votes with a positive feedback rating | 85% of 28359 |
Total "Very Satisfied" Votes | 20895 |
Total "Somewhat Satisfied" Votes | 6522 |
Total "Not Satisfied" Votes | 942 |