about | help | code help+videos | done | prefs |
Given an array nums, return a new array that contains the first half of the elements. The resulting array should have a length of firstHalfArray([1, 2, 1, 1]) → [1, 2] firstHalfArray([1, 2, 1]) → [1] firstHalfArray([1]) → [] ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Copyright Nick Parlante 2017 - privacy