import java.util.Scanner; 

/**
 * This class asks the user for two integers and does
 * five mathematical operations on them.
 */
public class Calculator
{
	/* This is the main method. The program starts here. */
	public static final void main(String[] args)
	{
		// create a Scanner object to read from the keyboard
		Scanner scan = new Scanner(System.in);

		// ask the user to enter the first number
		System.out.print("Please enter a number: ");

		// read what the user types
		int x = scan.nextInt();

		// ask the user to enter the second number
		System.out.print("Please enter another number: ");

		// read what the user types
		int y = scan.nextInt();

		// calculate the sum
		int sum = x + y;
		System.out.println("The sum is " + sum);

		// calculate the difference
		int diff = x - y;
		System.out.println("The difference is " + diff);

		// calculate the product
		int prod = x * y;
		System.out.println("The product is " + prod);

		// calculate the quotient (as an integer)
		int quot = x / y;
		System.out.println("The quotient (as an integer) is " + quot);

		// calculate the quotient (as a float)
		float quotf = (float)x / y;
		System.out.println("The quotient (as a float) is " + quotf);

		// calculate the modulus
		int mod = x % y;
		System.out.println("The modulus is " + mod);
	}
}
