Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Write a program that reads in two arrays (a1 and a2) of numbers and creates a new array (a3) of numbers such that the

1. Write a program that reads in two arrays (a1 and a2) of numbers and creates a new array (a3) of numbers such that the new array contains all the unique numbers of a1 and a2. Assume the input array elements are unique elements. In the main function, ask the user to enter the length of each array, declare and reads in the numbers for each array, and calculate and display the output array.

Example input/output #1: Enter the length of array 1: 5 Enter the elements of the array: 8 4 1 3 9 Enter the length of array 2: 3 Enter the elements of the array: 5 4 8

Output array: 8 4 1 3 9 5

Example input/output #2: Enter the length of array 1: 4 Enter the elements of the array: 3 4 1 7 Enter the length of array 2: 2 Enter the elements of the array: 6 9

Output array: 3 4 1 7 6 9

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Hands-On Database

Authors: Steve Conger

2nd Edition

0133024415, 978-0133024418

More Books

Students also viewed these Databases questions

Question

=+ a. a family deciding whether to buy a new car

Answered: 1 week ago

Question

=+10. How are inflation and unemployment related in the short run?

Answered: 1 week ago