id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

mergeTwo


Given two non-empty arrays of int values that are arranged in ascending order (i.e. sorted), create and return a new array with all the values of each array 'merged' into one (also arranged in sorted order).


mergeTwo([2, 3, 5], [4, 8]) → [2, 3, 4, 5, 8]
mergeTwo([1, 8], [2, 3, 5]) → [1, 2, 3, 5, 8]
mergeTwo([2, 8], [4, 7, 8]) → [2, 4, 7, 8, 8]

...Save, Compile, Run (ctrl-enter)

int[] mergeTwo(int[] nums1, int[] nums2) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Copyright Nick Parlante 2017 - privacy