Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write in JAVA Don't copy paste from chatgpt 1 . Write a program with a while loop that will display numbers in the range 1

Write in JAVA
Don't copy paste from chatgpt
1. Write a program with a while loop that will display numbers in the range 1 to 30, divisible by 3.
2. Prepare a program that prints even numbers in the range 1 to 30. Use a for loop and a continue
statement.
3. Prepare an alphabet function that takes the letter x as an argument and displays the letters 'a' to x.
Use a while loop.
4. Write a program that uses do - while statements to add integers from 1 to x.
5. Prepare a function that uses the for statement to sum the even numbers in the range 0 to x.
Use the modulo% operator.
6. Prepare a program that displays numbers from -100 to 100 in descending order. Numbers
should be divisible by 2, but not divisible by 3 and 8. Complete the task using the continue
statement.
7. During the ski jumping competition the competitor receives style marks from 5 judges. The
final grade for style is equal to the sum of the three that will remain after rejecting the extreme marks (i.e. the smallest and the largest). Write a program that reads 5 numbers from 0
to 20 into an array, and then calculates the style marks according to the rules above.
8. Write an algorithm that will fill the square table as shown below and display n rows and columns.
Below is an example for n equal to 5
11111
12222
12333
12344
12345
9. Implement the algorithm that calculates the fibonacci numbers using the recursive and iterative method

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

Step: 3

blur-text-image

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

Essentials of Database Management

Authors: Jeffrey A. Hoffer, Heikki Topi, Ramesh Venkataraman

1st edition

133405680, 9780133547702 , 978-0133405682

More Books

Students also viewed these Databases questions

Question

Provide examples of Dimensional Tables.

Answered: 1 week ago