Coding Exercise - How to Merge Two Sorted Array? 编程练习题 - 如何合并两个有序的数组?

in #programming8 years ago (edited)

Task: Merge two given sorted integer array A and B into a new sorted integer array. Example A=[1,2,3,4], B=[2,4,5,6], return [1,2,2,3,4,4,5,6]

XXX: https://helloacm.com/coding-exercise-how-to-merge-two-sorted-array/

Support me and my work as a witness - witness thread by

  1. voting me here, or
  2. voting me as a proxy.

Thank you! Some of My Contributions: SteemIt Tutorials, Robots, Tools and APIs


题意:合并两个已经排序好的数组。这也是合并排序的最后一步操作。还算比较简单的,你可以从数组的两端开始。一般来说从小到大合并会比较直观。

XXX同步到我的博文: https://justyy.com/archives/6417

支持我的工作 支持我成为 见证人

  1. 请在 这里 投我一票, 或者
  2. 设置我 为代理.

谢谢您! 我的贡献:SteemIt 工具、API接口、机器人和教程

股东工具

  1. 成为股东:代理5 SP 即可 (退出股东 输入 0即可)
  2. 查询当前股东

请注意:每次代理都是以最后一次输入的SP数量为标准,比如已经代理10 SP,想多代理5 SP则需要输入 最后的数字 15 SP(而不是 5!)

Sort:  

Hello! Your post has been resteemed and upvoted by @ilovecoding because we love coding! Keep up good work! Consider upvoting this comment to support the @ilovecoding and increase your future rewards! ^_^ Steem On!

Reply !stop to disable the comment. Thanks!

Excelente Post . Que tenga feliz noche

跟着行长学编程,学成了黑两个交易所玩玩

Posted using Partiko Android

It was $4.20 so I had to upvote... it’s a sign 😎

Posted using Partiko iOS

Coin Marketplace

STEEM 0.04
TRX 0.33
JST 0.081
BTC 60803.79
ETH 1617.36
USDT 1.00
SBD 0.42