Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a function with your netid as the name. It should take one input, array 1 . It should return one output, out 1 .

Write a function with your netid as the name. It should take one input, array1. It should return one output, out1.
array1 is an array with 3 elements.
Define the following values in your function:
m - The number that is the largest value in array1.
n - The sum of all of the numbers in array1.
k - The number in the 1st index of array1.
out1 should be m/k + n.
You may not use the commands min, max, or sum in this function. Assume that all elements of array1 are different.
B. How many test cases do you need for this function? Why?

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

Refactoring Databases Evolutionary Database Design

Authors: Scott Ambler, Pramod Sadalage

1st Edition

0321774515, 978-0321774514

More Books

Students also viewed these Databases questions