Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Math functions on 2 arrays Must Compile or Zero points incorrect results lose 1 2 points Do not turn in code that does not compile
Math functions on arrays Must Compile or Zero points
incorrect results lose points
Do not turn in code that does not compile
Do not turn in code that has not been tested
All variable declarations are at the top and followed by a blank line
All output must be aligned as shown above
Must use scientific notation in print statement as shown above
The arrays must be declared as int
Take int arrays and perform the following mathematical operations using the respective elements of each array:
Print the raised to the power of the
Print the square root of the sum of the elements
Print the square of the sums of the elements
Print the results in their respective columns with the following header as shown:
Create arrays and assign them as follows:
Array is the numbers from above
Array is the numbers from above
The powers column must use scientific notation if the number exceeds the column width.
Use the following:
For the square root of the sum column:
The elements are added first, then the square root is taken
For the sum of the squares column:
The elements are added first, then they are squared
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started