Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I am using c language and dev c compiler. 1. Write a program which will take 10 integers between 1 and 20, as input from

image text in transcribed

I am using c language and dev c compiler.

1. Write a program which will take 10 integers between 1 and 20, as input from the user, store them in an array named as userInputs. In your program, define an array named as referenceNumbers with numbers given below. For each corresponding elements in both arrays with same index, calculate maximum absolute difference between corresponding elements. Numbers for referenceNumbers array: {7, 1, 9, 3, 4, 15, 11, 2, 19, 12} 4 19 9 10 12 10 2 6 4 Examples: If user inputs 1, 4, 2, 8, 17, 4, 11, 5, 9, 10 numbers, differences will be; Reference Array 7 1934 | 15 | 11 2 User Array 1 4 2 8 17 115 Absolute Difference 63 7 5 13 0 3 Maximum Absolute Difference 13 (with sh elements) Example output: Welcome. Please input 10 integers between 1 and 20. 1. number: 6 2. number: 4 3. number: 5 3 4. number: 3 2 5. number: 2 1 6. number: 1 2 7. number: 2 3 8. number: 3 4 9. number: 4 5 10. number: 5 Maximum difference is 15 for 9. elements. 5

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

Step: 3

blur-text-image

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

Professional IPhone And IPad Database Application Programming

Authors: Patrick Alessi

1st Edition

0470636173, 978-0470636176

More Books

Students also viewed these Databases questions

Question

Distinguish between disidentification and discounting.

Answered: 1 week ago

Question

1. Identify six different types of history.

Answered: 1 week ago

Question

2. Define the grand narrative.

Answered: 1 week ago

Question

4. Describe the role of narratives in constructing history.

Answered: 1 week ago