6 kyu
Create Phone Number
127,089 of 349,872xDranik
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 | 594784 |
Total Skips | 47960 |
Total Code Submissions | 806390 |
Total Times Completed | 349872 |
JavaScript Completions | 127089 |
CoffeeScript Completions | 334 |
Ruby Completions | 9134 |
Java Completions | 39555 |
Dart Completions | 2099 |
Haskell Completions | 1810 |
C# Completions | 22704 |
Python Completions | 115246 |
Scala Completions | 966 |
Groovy Completions | 157 |
Crystal Completions | 66 |
PowerShell Completions | 314 |
Go Completions | 4574 |
C Completions | 4524 |
NASM Completions | 63 |
Rust Completions | 3262 |
PHP Completions | 6629 |
Clojure Completions | 407 |
C++ Completions | 14155 |
Julia Completions | 169 |
CFML Completions | 42 |
Factor Completions | 19 |
F# Completions | 98 |
COBOL Completions | 38 |
Lua Completions | 333 |
TypeScript Completions | 4159 |
BF Completions | 50 |
Total Stars | 3740 |
% of votes with a positive feedback rating | 85% of 28326 |
Total "Very Satisfied" Votes | 20870 |
Total "Somewhat Satisfied" Votes | 6517 |
Total "Not Satisfied" Votes | 939 |