subject

The following code does not work as intended. it is meant to input two test grades and return the average in decimal format:

int test1 = scan. nextint();
int test2 = scan. nextint();
double average = (test1 + test2 )/2;
system. out. println(" " + average);
which of the following corrections will allow the code to work as intended?

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 03:00
How can i clip a picture to a question on the computer?
Answers: 1
question
Computers and Technology, 22.06.2019 06:00
What role do chromosomes play in inheritance?
Answers: 1
question
Computers and Technology, 22.06.2019 08:30
Active listen eliminates barries to communication true or false
Answers: 1
question
Computers and Technology, 22.06.2019 15:10
Consider a direct-mapped cache with 216 words in main memory. the cache has 16 blocks of 8 words each. it is a word-addressable computer (rather than a byte-addressable computer which we normally discuss). (a) how many blocks of main memory are there? (b) what is the format of a memory address as seen by the cache, that is, what are the sizes of the tag, cache block, and block offset fields (if they apply)? (c) to which cache block will the memory reference db6316 map?
Answers: 1
You know the right answer?
The following code does not work as intended. it is meant to input two test grades and return the av...
Questions
question
Social Studies, 25.06.2019 03:00
Questions on the website: 13722362