cheerkennedym5520 cheerkennedym5520
  • 19-02-2020
  • Mathematics
contestada

You have three int variables called a, b and c. Write a Java statement which creates a variable d and assigns its value to the mean of a, b and c.

Respuesta :

fahadisahadam
fahadisahadam fahadisahadam
  • 21-02-2020

// creates variable

int a;

int b;

int c;

// Now assign value to a variable

// let me give them a value

a = 10;

b = 20;

c = 30;

mean= (a + b + c ) / 3;

// print mean

System.out.println("The mean is : " + mean);

The out will be 20.

Answer Link

Otras preguntas

What does score mean in design and technology?
If f(x) varies directly with x and f(x) = 2 when x = 10, then what is the value of f(x) when x = 40? a.8 b.45 c.200 d.320
4.016 as mixed number
Can someone please write a concluding paragraph for this essay based on what I already have? Negative Effects of Reality TV on Teenagers By Angel Maroone Realit
The subregion of the United states most aided by the deveolpment of irigation and air conditioning was?
What is a palindrome for a paper that shows legal ownership of property?
Freddie used 6.75 gallons of gas to drive the 155.25 miles. What was his car's gas mileage? (gallons per mile)?
In 1900, which nation controlled more territory than any other imperial nation? Great Britain Japan Germany United States
Thomas Jefferson was concern that the treaty formalizing the Louisiana Purchase
What three things do plants need to make sugar?