Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using java Write a program with a main method that asks the user to enter an array of 10 integers. Your main method then calls

Using java image text in transcribed
Write a program with a main method that asks the user to enter an array of 10 integers. Your main method then calls each of the three methods described below and prints out the results of the two methods which return values printReverse- a void method that reverses the elements of the array and prints out all the elements in one line separated by commas (see sample output below). getLargest- an int method that returns the largest value in the array computeTwice- a method that returns an array of int which contains 2 times of all the numbers in the array (see the sample output below). Sample output: Enter a number: Enter a number 34 Enter a number: 21 Enter a number 35 Enter a number 12 Enter a number Enter a number: Enter a number: Enter a number: Enter a number 81 Here the array in reverse: 81, 99, 3,2, 4, 12, 35, 21, 34, 22 The highest number is 99 The array with two times the numbers: [162, 198, 6,4, 8, 24, 70, 42, 68, 44]

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

More Books

Students also viewed these Databases questions

Question

How is the IETF related to the IRTF?

Answered: 1 week ago

Question

understand the key issues concerning international assignments

Answered: 1 week ago