| about | help | code help+videos | done | prefs |
alternate
Combine two arrays into a new array, with each element alternating in the new array, starting with the first element of the first array. alternate(["a", "yes", "no", "maybe", "ok"], ["one", "two", "three", "four"]) → ["a", "one", "yes", "two", "no", "three", "maybe", "four", "ok"] alternate(["A", "B", "C", "D", "E"], ["1", "2", "3", "4", "5"]) → ["A", "1", "B", "2", "C", "3", "D", "4", "E", "5"] alternate(["q", "w", "e", "r", "t", "y", "u", "i", "o", "p"], ["key", "board", "letters", "numbers", "words", "typing", "asdf", "keyboard", "ghjkl"]) → ["q", "key", "w", "board", "e", "letters", "r", "numbers", "t", "words", "y", "typing", "u", "asdf", "i", "keyboard", "o", "ghjkl", "p"] ...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