Comsats University Islamabad Wah Campus Object Oriented Programming
Comsats University Islamabad Wah Campus Object Oriented Programming
Comsats University Islamabad Wah Campus Object Oriented Programming
Wah Campus
Submitted by:
System.out.println(Calculator.multiply(sc.nextInt(),
sc.nextInt()));
break;
case 4:
System.out.println("Enter two values to be
divided");
System.out.println(Calculator.divide(sc.nextInt(),
sc.nextInt()));
break;
case 5:
System.out.println("Enter two values for
modulus");
System.out.println(Calculator.modulus(sc.nextInt(),
sc.nextInt()));
break;
case 6:
System.out.println("Enter angle value");
System.out.println(Calculator.sin(sc.nextInt()));
break;
case 7:
System.out.println("Enter angle value");
System.out.println(Calculator.cos(sc.nextInt()));
break;
case 8:
System.out.println("Enter angle value");
System.out.println(Calculator.tan(sc.nextInt()));
break;
}
Task 3
Distance Runner Distance
import java.util.Scanner;
public class Distance {
public class DistanceRunner { private double feets;
private double inches;