Determine and display the smallest and largest values contained in 99-element floating- point array w.
What will be an ideal response?
```
double small = w[0];
double large = w[0];
for (int i = 0; i < w.length; i++)
if (w[i] < small)
small = w[i];
else if (w[i] > large)
large = w[i];
System.out.printf("%f %f%n", small, large);
```
You might also like to view...
A menu system may consist of each of the following, EXCEPT:
A) check box menu item B) combo box menu item C) radio button menu item D) menu item
Answer the following statements true (T) or false (F)
1. Under KDE, click the Konsole icon to switch to GUI mode. 2. UNIX line command names are generally self evident, even to beginners. 3. The shell is a key UNIX component that allows a user to identify, save, and retrieve files by name. 4. A UNIX file name consists of from 1 to 8 characters. 5. UNIX distinguishes between upper and lower case characters in a file name.
Which of the following is a streaming player for your TV that can use your home's wireless network to connect with online services such as Netflix and Pandora?
A. Spotify B. Glass C. OnLive D. Roku
Why is it a good idea to add some extra drops when you install the cable initially?
What will be an ideal response?