CSE110 – 1)

$ 29.99
Category:

Description

a. 24, 18, 12, 6, 0, -6
b. -10, -5, 0, 5, 10, 15, 20
c. 18, 27, 36, 45, 54, 63
d. 18,-27,36,-45,54,-63

2) Java program, which adds all numbers that are multiples of both 7 and 9 up to 600.

3) Java program, which adds all numbers that are multiples of either 7 or 9 or both up to 600. Ensure that numbers like 63 are added only once in the sum.

4) Java program, which adds all numbers that are multiples of either 7 or 9 but not both, up to 600.

5) Java program that asks the user for 20 numbers and prints if those numbers are odd or even.

6) Java program that asks the user for a quantity , then takes that many numbers and prints if those numbers are odd or even.

7) Java program that asks the user for a quantity , then takes that many numbers and prints the maximum, minimum and average of those numbers.

8) Java program that takes a number from user and prints the divisors of that number and then how many divisors there were. If user gives 6, your program should print, 1, 2, 3, 6, total 4 divisors.. If user gives 121, your program should print 1,11,121, total 3 divisors.

9) An integer number is said to be a perfect number if its factors, including 1 but not the number itself, sum to the number. For example, 6 is a perfect number because factors of 6 are 1, 2, 3, 6 and if we add all factors except itself, 6 = 1 + 2 + 3. Java program, which takes a number and tells if it is a perfect number or not.

10) Java program that asks user for one number and tells if it is a prime number or not. Hint: use the divisor count from task 8. If a number has only two divisors, (1 and itself), then it is prime. If it is divisible by more numbers, then it is not a prime.

11) Java program that prints all prime numbers between 40 and 50.

Page 1 of 1

Reviews

There are no reviews yet.

Be the first to review “CSE110 – 1)”

Your email address will not be published. Required fields are marked *