Check if current element of first array is smaller than current element of second array . If yes , store first array element and increment first array index . Otherwise do same with second array
if arr1 [ i ] < arr2 [ j ] : NEW_LINE INDENT arr3 [ k ] = arr1 [ i ] NEW_LINE k = k + 1 NEW_LINE i = i + 1 NEW_LINE DEDENT else : NEW_LINE INDENT arr3 [ k ] = arr2 [ j ] NEW_LINE k = k + 1 NEW_LINE j = j + 1 NEW_LINE DEDENT