Question: 1 . Open NetBeans and Create a New Project Open NetBeans. Click on File in the top menu. Select New Project... 2 . Choose Project
Open NetBeans and Create a New Project
Open NetBeans.
Click on "File" in the top menu.
Select "New Project..."
Choose Project Type
In the "New Project" dialog, select "Java with Ant" category.
Choose "Java Application" and click "Next."
Set Project Name and Location
Enter a name for your project eg "OOP"
Choose a project location or leave the default storage location.
Uncheck the Create Main Class Option.
Click "Finish."
Creating a New Package and Class
Create a Class
In the "Projects" tab on the left, expand the "OOP" project.
Rightclick on "Source Packages." make sure you click on the name and not just close to it
Select "New" "Java Class..."
Name the class Give it the name of a realworld object you identified and click "Finish."
State the object realworld entity you have identified. Briefly describe what this entity has and what it can do
Write Java Code to implement the created class.
Identify and declare at least three instance variables all should be public
Identify and declare at least three class variables all should be public
Write the default constructor for the class that initializes all the classstatic variables.
Write a parameterized constructor for the class that initializes all the instance variables.
Write a method that returns void and takes in no parameters.
Write a method that returns a given data type but takes in no parameters.
Write a method that returns a given data type and takes in at least one parameter.
Write a method called introduce that when calledinvoked will output at least one instance variable and one static variable.
Add comments for what each of the method does.
Explain how you have used a local variable and parameter in the methods above.
Creating a Test Class and Instantiating.
Creating the Test Class.
In the "Projects" tab on the left, expand the "OOP" project.
Rightclick on "Source Packages."
Select "New" "Java Class..."
Name the class Test.
Write Java code for the Test Class.
Inside the two curly brackets, write the main method for a java program.
Inside the main method in java:
o Create at least two objects.
o Instantiate the two objects with the default constructor.
o Create at least two more objects.
o Instantiate the two more objects with the parameterized constructor.
o Call the introduce method using all the objects you have created.
o Bonus: write you own code in the main class using the objects, which will demonstrate the use of control flow structures.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
