about | help | code help+videos | done | prefs |
middle
Complete the function so that x is inserted into the middle of the list. nums will have a positive, even length. The function returns the list with x in the middle. middle([12, 1, 50, 2], 3) → [12, 1, 3, 50, 2] middle([17, 5], 2) → [17, 2, 5] middle([3, 3, 3, 3, 3, 3], 8) → [3, 3, 3, 8, 3, 3, 3] ...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: 200
Copyright Nick Parlante 2017 - privacy