Assume variables first, second, and max are declared to be double and are initialized. Write a sequence of lines of code that cause the larger of the values in first and second to be stored in max.

What will be an ideal response?


//double first, second, max
//first and second have been initialized
if ( (first < second) )
max = second;
else
max = first;
//assert: max >= first && max >= second

Computer Science & Information Technology

You might also like to view...

After reviewing slides, you can change the view to ____________________ so that you may continue working on a presentation.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

The PC ________ feature can return your PC to the condition it was in at the time of purchase

Fill in the blank(s) with correct word

Computer Science & Information Technology

A(n) ____________________ is the first letter of a paragraph that has been styled to be larger in size and to drop down into the text of the paragraph.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

Identify the letter of the choice that best matches the phrase or definition.

A. A rule that can be used in a mail merge operation B. A type of data source that can be used in mail merge operations C. A comparison category used for filtering a data source D. A complete set of information for one recipient in a data source E. A field that can be used in a mail merge operation

Computer Science & Information Technology