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
jeka94
2 years ago
13

What is the output by the code system.out.print(8-4+2);

Computers and Technology
1 answer:
Nonamiya [84]2 years ago
4 0

Answer:

6

Explanation:

You might be interested in
True or false.local and cloud backup differs in where the backup is saved
Feliz [49]

I think this is true.

7 0
3 years ago
Read 2 more answers
Write a method drivingCost() with input parameters drivenMiles, milesPerGallon, and dollarsPerGallon, that returns the dollar co
aleksklad [387]

Answer:

public static double drivingCost(int drivenMiles, double milesPerGallon,double dollarsPerGallon){

       return (drivenMiles/milesPerGallon)*(dollarsPerGallon);

   }

Find a complete java program that prompts the user to enter this values and the calls this Method in the explanation section.

Explanation:

<em>import java.util.Scanner;</em>

<em>public class ANot {</em>

<em>    public static void main(String[] args) {</em>

<em>    Scanner in = new Scanner(System.in);</em>

<em>        System.out.println("Please Enter the Driven Miles");</em>

<em>        int drivenMiles = in.nextInt();</em>

<em />

<em>        System.out.println("Please Enter the Your fuel consumption in miles/gallon");</em>

<em>        double milesPerGallon = in.nextDouble();</em>

<em />

<em>        System.out.println("Please Enter the cost of fuel in Dollars/gallon");</em>

<em>        double dollarsPerGallon = in.nextDouble();</em>

<em />

<em>        double dollarCost = drivingCost(drivenMiles,milesPerGallon,dollarsPerGallon);</em>

<em>        System.out.println("The Total Cost in Dollars is "+dollarCost);</em>

<em>        }</em>

<em>    public static double drivingCost(int drivenMiles, double milesPerGallon,double dollarsPerGallon){</em>

<em />

<em>        return (drivenMiles/milesPerGallon)*(dollarsPerGallon);</em>

<em>    }</em>

<em>}</em>

8 0
3 years ago
Which of the following is the correct binary representation of the number 2?
dusya [7]

Answer:

10

Explanation:

To convert decimal to binary, you just count like normal, but instead of regrouping when adding 1 when you reach 9, you regroup when you reach 1.

in this case, you would count like this:

0

1

10

7 0
2 years ago
1. Se requiere implementar un conversor unipolar que tendrá una tensión analógica variable entre 0 y 2 V pico. Deberá tener una
PolarNik [594]

Answer:

A

Explanation:

Because

7 0
3 years ago
Which task is not possible with VLOOKUP?
Flauer [41]

Answer:c

Explanation:

4 0
3 years ago
Read 2 more answers
Other questions:
  • What is the solubility of an empty soda can
    10·1 answer
  • When CPU failed what will happen?
    10·1 answer
  • Richard needs to copy information from another slide presentation that uses a different design template. To ensure that the info
    7·1 answer
  • When network cards are communicating, bits can occasionally be corrupted in transmission?
    5·1 answer
  • Kevin manages the security for his company and is working to implement a kernel integrity subsystem for key servers. Of the foll
    9·1 answer
  • 3.3 Code Practice: Question 1
    15·1 answer
  • Explain in your own words how remote-access Trojans (RATs) work. How can these be used by attackers? How would a network adminis
    10·1 answer
  • What will the following code display?
    12·1 answer
  • In a _____, there is no skipping or repeating instructions. A. iteration B. sequence C. selection D. conditional
    10·1 answer
  • When you start a new, blank document, you usually end up changing the font to arial 11. 5 point. How can you make these settings
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!