about | help | code help+videos | done | prefs |
APCS Array 2, Problem 12. Given an int array of any length, return a new array of its first 2 elements. If the array is smaller than length 2, use whatever elements are present. A212_frontPiece([1, 2, 3]) → [1, 2] A212_frontPiece([1, 2]) → [1, 2] A212_frontPiece([1]) → [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
Difficulty: 100
Copyright Nick Parlante 2017 - privacy