123456789101112131415161718
  1. public class ShortCalculator {
  2. public Short[] shortValues(short num1, short num2){
  3. short sum = (short)(num1+num2);
  4. short difference = (short)(num1 - num2);
  5. short product = (short)(num1 * num2);
  6. short quotient = (short)(num1 / num2);
  7. short remainder = (short)(num1 % num2);
  8. Short[] x = {sum, difference, product, quotient, remainder};
  9. return x;
  10. }
  11. }