7 kyu
Get array elements with specified keys
583int3_0xcc
Description:
Create a function that lets people easily grab only the array elements with given keys.
For example:
var array = ['a', 'b', 'c', 'd', 'e'];
array2 = array.only([0, 3]);
// at this point array2 should be ['a', 'd']
Note: The order of the elements should be preserved in the resulting array.
Arrays
Fundamentals
Similar Kata:
Stats:
Created | Jan 2, 2017 |
Published | Jan 2, 2017 |
Warriors Trained | 847 |
Total Skips | 14 |
Total Code Submissions | 2829 |
Total Times Completed | 583 |
JavaScript Completions | 583 |
Total Stars | 10 |
% of votes with a positive feedback rating | 87% of 214 |
Total "Very Satisfied" Votes | 168 |
Total "Somewhat Satisfied" Votes | 35 |
Total "Not Satisfied" Votes | 11 |
Total Rank Assessments | 53 |
Average Assessed Rank | 7 kyu |
Highest Assessed Rank | 5 kyu |
Lowest Assessed Rank | 8 kyu |