Question: Write code that stores all odd numbers between -6 and 38 into an array using a loop. Make the arrays size exactly large enough to

Write code that stores all odd numbers between -6 and 38 into an array using a loop. Make the array’s size exactly large enough to store the numbers.

Then, try generalizing your code so that it will work for any minimum and maximum values, not just -6 and 38.


Step by Step Solution

3.43 Rating (178 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Code that stores all odd num... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Building Java Programs A Back to Basics Approach Questions!