Question: Create a Java class with name: Assignment1 Create the main() method in this class In the main() method do Declare two variables of types int

  1. Create a Java class with name: Assignment1
  2. Create the main() method in this class
  3. In the main() method do
    1. Declare two variables of types int and double respectively, and then initialize them.
    2. Print the values of the two variables using two println() statements.
    3. Show one use of the if statement.
    4. Use one for-loop statement to output the following rectangle of stars.

**********

**********

**********

At the beginning of your program, provide the following information

Assignment number:

Programmer name:

Due date:

Program file name: Welcome.java (for say)

Comments: should describe what your programs want to do. There are usually five types of comments on

  1. classes, telling what they do
  2. variables, telling their meanings
  3. methods, showing their purposes
  4. algorithms, describing their goals and key steps
  5. a piece of code, showing its purpose and key steps

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!