andrusandy43 andrusandy43
  • 22-03-2021
  • Computers and Technology
contestada

Write and compile a java code to add 18+6?

Respuesta :

klekaelly
klekaelly klekaelly
  • 22-03-2021

Answer:

public class testing

{

   public static void main(String[] args)

   {

       int x = 18;

       int y = 6;

       System.out.println(addNumbers(x, y));

   }

   public static int addNumbers(int a, int b)

   {

       return a + b;

   }

}

Answer Link

Otras preguntas

What were the most popular crops during the dust bowl
FIRST ONE WHO ANSWERS THIS QUESTIN WILLLL BEEE MARKED BRAINLIEST. YOU MAY COPY FORM OTHER WEBSITES Look at the photograph of a fault found in Klamath Falls, Ore
What is the definition of a dihybrid cross?
Which equation is represented by the graph? Please hurry and help A: 3x - 2y = 12 B: 2x + 3y = 12 C: 2x - 3y = 12 D: 3x + 2y = 12
a man can run at a speed of 13 feet per second on land. at this rate how far can it run in 3 seconds
Halp? The cargo area of a truck is 8 1\2 feet long, 6 feet wide, and 10 1\2 feet high. The volume of the cargo area is cubic feet.
Many of the people in Sub-Saharan Africa speak more than one language because
How does aspirin interact with other drugs
Which statement is true for the equation 4x - 4x - 5= -5 No solution One solution Two solutions Infinitely many solutions
The functioning of enhancers is an example of