Author Question: What is the value of average after the following code executes? double average;average = 1.0 + 2.0 + ... (Read 157 times)

AEWBW

  • Hero Member
  • *****
  • Posts: 579
What is the value of average after the following code executes?
double average;
average = 1.0 + 2.0 + 3.0 / 3.0;

3.0
4.0
2
2.0
◦ unknown



Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question


 

Did you know?

Cancer has been around as long as humankind, but only in the second half of the twentieth century did the number of cancer cases explode.

Did you know?

Autoimmune diseases occur when the immune system destroys its own healthy tissues. When this occurs, white blood cells cannot distinguish between pathogens and normal cells.

Did you know?

Drug abusers experience the following scenario: The pleasure given by their drug (or drugs) of choice is so strong that it is difficult to eradicate even after years of staying away from the substances involved. Certain triggers may cause a drug abuser to relapse. Research shows that long-term drug abuse results in significant changes in brain function that persist long after an individual stops using drugs. It is most important to realize that the same is true of not just illegal substances but alcohol and tobacco as well.

Did you know?

Recent studies have shown that the number of medication errors increases in relation to the number of orders that are verified per pharmacist, per work shift.

Did you know?

Cytomegalovirus affects nearly the same amount of newborns every year as Down syndrome.

For a complete list of videos, visit our video library