Assume variables first and second are declared to be double and are initialized. Write a sequence of lines of code that cause the values stored in first and second to be exchanged if the value of first is not less than second.

What will be an ideal response?

```
// double first, second;
// these have been initialized
if (!(first < second))
{
double temp = first;
first = second;
second = temp;
}
//assert: first <= second

```

Computer Science & Information Technology

You might also like to view...

The Windows feature ________ allows the user to choose which program to use to start different kinds of media, such as CDs or DVDs

Fill in the blank(s) with correct word

Computer Science & Information Technology

What part of a laser printer should you be concerned about disposal?

A) Toner B) Conditioning roller C) Misfed paper D) Paper debris

Computer Science & Information Technology