1. Learn
  2. /
  3. Courses
  4. /
  5. Intermediate Julia

Exercise

Array merging

In some situations, you might have multiple arrays and want to combine them together into one large array.

In this example, we have two arrays of stock tickers, stocks_yesterday and stocks_today. The first array contains stock tickers we traded yesterday, and the second array contains stock tickers that we traded today. We want to create a master array, with all tickers combined.

Remember that to merge two arrays, we use the semicolon operator ;, just as we do when creating a multi-dimensional array.

Instructions

100 XP
  • Merge stocks_yesterday and stocks_today and store the result in stocks_master.