Loading Posts...

Write a Java Program to ADD two number.

Write a Java Program to ADD two number.
import java.io.*;
(library function)
import java.util.*;
public class add

{
public static void main(string arg[])
{
int a,b,ADD;
Scanner sc=new Scanner(system.in);

System.out.println("enter a=");

a=sc.nextInt();

System.out.println("enter b=");
b=sc.nextInt();
ADD=a+b;

System.out.println("result="+ADD);

}
}

 

krish..

The author didnt add any Information to his profile yet

Leave a Comment

Loading Posts...
Inline
Inline