1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Airida [17]
3 years ago
6

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("Answer: " + average);
Computers and Technology
1 answer:
yuradex [85]3 years ago
6 0

Answer:

To return average in Decimal we will use float datatype instead of double.

Explanation:

int test1 = scan.nextInt();

int test2 = scan.nextInt();

float average = (test1 + test2 )/2;

System.out.println("Answer: " + average);

You might be interested in
Can anyone help me to write an example for html language​
ivann1987 [24]
No i cannot bcs i dont know
3 0
3 years ago
Read 2 more answers
Administrators who are wary of using the same tools that attackers use should remember that a tool that can help close an open o
In-s [12.5K]

Answer:

False.

Explanation:

Administrators showing caution in using the same tools that are used by the attackers remember that tool that can help to close a poorly configured or open firewall will help network defender and it will minimize the risk from the attack.

Hence the answer to this question is false.

6 0
3 years ago
What does the Attack Time slider let you set?
san4es73 [151]
B.how fast the compressor starts to work
4 0
4 years ago
A boy is sitting to the side of a campfire. He is 5 feet away, but still feels warm. This is an example of:
tiny-mole [99]
This is an Conduction
8 0
3 years ago
Consider a city of 10 square kilometers. A macro-cellular system design divides the city into square cells of 1 square kilometer
victus00 [196]

Answer:

1,000 users

10,000,000 users

Explanation:

Given the following :

Area of city = 10 square kilometers

Each cell = 1 square per kilometer

Number of users each cell can accommodate = 100

Total number of users that can be accommodated in the system :

(Total number of cells in the system * number of users per cell)

(10 sqkm / 1 sqkm) * 100

10 * 100 = 1,000 users

B) If cell size is reduced to 100 square meters

Converting 100 square meters to square km

100 sq meters = 0.0001 sq kilometers

Number of users each cell can accommodate = 100

Total number of users that can be accommodated in the new system :

(Total number of cells in the system * number of users per cell)

(10 sqkm / 0.0001 sqkm) * 100

100,000 * 100 = 10,000,000 users

6 0
3 years ago
Other questions:
  • A virus that propagates using the internet or another computer network is called __________.
    10·1 answer
  • Trish has bought a new computer that she plans to start working on after a week. Since Trish has not used computers in the past,
    10·1 answer
  • The it department is reporting that a company web server is receiving an abnormally high number of web page requests from differ
    13·1 answer
  • Advantages of purchasing a software package over developing software in-house include all of the following except ____. Group of
    13·1 answer
  • Help, I'm a beginner in coding! I have to write a quiz. You don't have to get all fancy and stuff, since I'm a beginner lol. I w
    12·1 answer
  • An array similar to a phone book has 1000 names arranged as names [0], names[1]....names[999]. Nancy wants to search a name X in
    15·1 answer
  • Can someone be my friend,don't friend me until i ask you Questions
    14·1 answer
  • What are some limitations when it comes to testing and ensuring program quality? List at
    15·1 answer
  • Execute and explain this program using // in Layman's language. Thank you!
    7·1 answer
  • 3. It is important to make certain that your employees are aware of the work ethic
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!