Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

6 . 1 8 LAB: User - Defined Functions: Adjust list by normalizing When analyzing data sets, such as data for human heights or for

6.18 LAB: User-Defined Functions: Adjust list by normalizing
When analyzing data sets, such as data for human heights or for human weights, a common step is to adjust the data. This can be done by normalizing to values between 0 and 1, or throwing away outliers. Define a function named getMinimumInt that takes an integer array as a parameter and returns the smallest value. Then write a main program that reads five integers as input, stores the integers in an array, and calls getMinimumInt() with the array as an argument. The main program then outputs the normalized array by subtracting the returned smallest value from all the values in the array.
Ex: If the input is:
3050107065
function getMinimumInt() returns 10, and the program output is:
204006055
For coding simplicity, follow every output value by a space, even the last one.
Your program should define and use a function:
Function getMinimumInt(integer array(?) userVals) returns integer minInt

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

Securing SQL Server Protecting Your Database From Attackers

Authors: Denny Cherry

3rd Edition

0128012757, 978-0128012758

More Books

Students also viewed these Databases questions

Question

2. Use a point system or model papers when grading essays.

Answered: 1 week ago

Question

What are the role of supervisors ?

Answered: 1 week ago