Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using Java and this website https://www.tutorialspoint.com/compile_java_online.php Program will be called Project2a a = 20, b = 8 Both a and b are integers Program to

Using Java and this website https://www.tutorialspoint.com/compile_java_online.php

Program will be called Project2a

a = 20, b = 8

Both a and b are integers

Program to compute:

1. Sum of a and b

2. Difference of a and b

3. Product of a and b

4. Quotient of a and b

5. Remainder of a and b (you use %)

6. You need: 5 variables: sum, difference, product,,quotient, and remainder

13. ==========================================================

14. // CSC 110 1300 Spring 2020 your name

15. // This calculates the sum, difference, product, // quotient, and remainder

16. public class project2a

18. {

19. public static void main (String[ ] args)

20. {

21. String name = CSC110, Jose Prez;

23. int a;

24. int b;

25. int sum;

26. int difference;

27. int product;

28. int quotient;

29. int remainder;

30. a = 20;

31. b = 8;

32. sum = a + b;

33. difference = a - b;

34. product =

35. quotient =

36. remainder=

37. // you should print all the 5 items you calculated40.

System.out.println (name);

41. System.out.println (..);

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Deductive And Object Oriented Databases Second International Conference Dood 91 Munich Germany December 18 1991 Proceedings Lncs 566

Authors: Claude Delobel ,Michael Kifer ,Yoshifumi Masunaga

1st Edition

3540550151, 978-3540550150

More Books

Students also viewed these Databases questions