Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Store the four arrays shown below in the main method of the demo file. Each array contains 7 0 data. Save the file as Topchyan
Store the four arrays shown below in the main method of
the demo file. Each array contains data. Save the file
as Topchyandemo Write an object of the class type to
transfer the arrays to the class file to compute the results.
Print the outputs from within the demo file.
Create a class called Topchyanhw Write methods to
compute and return values from four of the fifteen parts
select one from top one from one from one
from Name methods accordingly such as if it is part
Topchyan
Array product contain the names of five products.
Array, quantity contains the number of products bought
such as quantities of the product Socks or Caps etc.
Array, origin and destination contains the names of cities
that the products were originated and shipped to
Product Unit Cost
Socks $
Shoes $
Caps $
Ties $
Watches $
String product Ties "Shoes", "Ties", "Shoes", "Ties",
"Watches", "Watches", "Shoes", "Shoes", "Watches",
"Watches", "Ties", "Caps", "Watches", "Ties", "Shoes",
"Watches", "Caps", "Socks", "Shoes", "Shoes", "Caps",
"Caps", "Ties", "Watches", "Watches", "Ties", "Watches",
"Caps", "Watches", "Watches", "Socks", "Ties", "Watches",
"Socks", "Watches", "Caps", "Shoes", "Ties", "Socks",
"Shoes", "Ties", "Watches", "Socks", "Watches",
"Watches", "Watches", "Watches", "Watches", "Shoes",
"Watches", "Socks", "Ties", "Ties", "Ties", "Shoes",
"Caps", "Caps", "Caps", "Caps", "Ties", "Caps",
"Watches", "Watches", "Caps", "Shoes", "Caps",
"Watches", "Caps", "Shoes";
int quantity
;
String destination Summit "Clifton", "Atco", "Brick",
"Wall", "Newark", "Deal", "Clark", "Edison", "Atco", "Clark",
"Mahwah", "Clark", "Mahwah", "Newark", "Deal", "Atco",
"Clifton", "Edison", "Wall", "Clifton", "Wall", "Summit",
"Wall", "Wall", "Edison", "Wall", "Newark", "Brick", "Wall",
"Clifton", "Clifton", "Summit", "Newark", "Summit",
"Summit", "Deal", "Summit", "Atco", "Brick", "Newark",
"Mahwah", "Deal", "Mahwah", "Clark", "Edison", "Clifton",
"Atco", "Edison", "Clifton", "Clark", "Clark", "Deal",
"Mahwah", "Atco", "Brick", "Edison", "Edison", "Edison",
"Edison", "Edison", "Summit", "Brick", "Atco", "Clark",
"Wall", "Edison", "Clifton", "Deal", "Brick";
String origin Union "Nutley", "Newark", "Newark",
"Nutley", "Union", "Union", "Paramus", "Paramus", "Union",
"Paramus", "Newark", "Union", "Newark", "Paramus",
"Paramus", "Union", "Newark", "Nutley", "Nutley", "Union",
"Union", "Union", "Newark", "Union", "Union", "Nutley",
"Nutley", "Nutley", "Paramus", "Paramus", "Newark",
"Nutley", "Newark", "Union", "Nutley", "Newark", "Nutley",
"Nutley", "Union", "Nutley", "Nutley", "Newark", "Newark",
"Union", "Nutley", "Nutley", "Newark", "Union", "Union",
"Union", "Nutley", "Union", "Nutley", "Nutley", "Paramus",
"Newark", "Nutley", "Union", "Newark", "Nutley",
"Paramus", "Union", "Union", "Union", "Union", "Paramus",
"Nutley", "Union", "Nutley";
Total number of orders of each type of products that
were bought.
The total cost of all orders.
The total cost of all orders shipped to Wall.
The total number of orders shipped to Wall.
The total quantity of products shipped to Wall.
The total cost of Ties, shipped to Wall.
The total cost of the products Ties, Socks and
Watches shipped to Clifton, Brick and Newark.
The total number of orders that originated from Union.
The total number of orders where each order is $ or
more.
The total number of orders that originated from
Union where each order is $ or more.
The total cost of orders that originated from
Union where each order is $ or more.
The total number of orders that originated from
Union and shipped to Edison.
The total cost of orders that originated from
Union and shipped to Edison.
The total number of orders that was shipped to all
destinations except to Edison.
The total cost of orders that was shipped to all
destinations except to Edison.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started