Okay guys today i will be teaching you how to make a simple addition calculator using Joption in java, I saw someone wrote some codes to calculate addition also it uses Java Scanner. This is that program .
import java.util.Scanner; class basic_cal { public static void main(String args[]) { Scanner shim = new Scanner(System.in); double first_number,second_number,answer; System.out.println("Enter First Number : "); first_number = shim.nextDouble(); System.out.println("Enter Second Number : "); second_number = shim.nextDouble(); answer = first_number + second_number; System.out.println("Answer : " + answer); } }Okay now i saw that and got an idea to make the same thing with Joption , Joption is like the messagebox we have in c# and vb.net ok , this is the program i wrote :