Content-Length: 535 | pFad | https://github.com/sagargoswami2001/Java-Lab-File-Programs/raw/refs/heads/main/Q1_CLI_Argument.java

gth: 523 //Q1. WAP to enter two numbers using command line argument and calculate their sum and multiplication. package JAVA_Lab_File; public class Q1_CLI_Argument { public static void main(String[] args) { int sum = Integer.parseInt(args[0]) + Integer.parseInt(args[1]); int multiplication = Integer.parseInt(args[0]) * Integer.parseInt(args[1]); System.out.println("Sum of two CLI Arguments: " + (sum)); System.out.println("Multiplication of two CLI Arguments: " + (multiplication)); } }








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/sagargoswami2001/Java-Lab-File-Programs/raw/refs/heads/main/Q1_CLI_Argument.java

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy