
Java Programming (MindTap Course List)
9th Edition
ISBN: 9781337397070
Author: Joyce Farrell
Publisher: Cengage Learning
expand_more
expand_more
format_list_bulleted
Concept explainers
Question
Chapter 10, Problem 7PE
Program Plan Intro
Shipping cost
Program plan:
Filename: “InsuredPackage.java”
- Define of “InsuredPackage” class
- Define constructor
- Call the “super” method
- Declare the constant variables with the values.
- Check “getCost ()” is less than “LOWCOST”
- Set “i” is “LOWINS”
- Check “getCost ()” is less than “MEDCOST”
- Set “i” is “MEDINS”
- Otherwise, set “i” is “HIGHINS”
- Call the “increaseCost()” method.
- Define constructor
Filename: “Package.java”
- Define the “Package” class
- Declare the required private variables
- Define the parameterized constructor
- Set the values
- Call the method
- Define the “calculateCost” method
- Declare the variable
- Check “w” is less than “LOWWT”
- Check “m” is equal to “AIR”
- Set “c” is “LOWAIR”
- Otherwise, check “m” is equal to “TRUCK”
- Set “c” is “LOWTRUCK”
- Otherwise, set “c” is “LOWMAIL”
-
- Check “w” is less than “MEDWT”
- Check “m” is equal to “AIR”
- Set “c” is “MEDAIR”
- Otherwise, check “m” is equal to “TRUCK”
- Set “c” is “MEDTRUCK”
- Otherwise, set “c” is “MEDMAIL”
- Check “m” is equal to “AIR”
- Check “w” is less than “HIGHWT”
- Check “m” is equal to “AIR”
- Set “c” is “HIGHAIR”
- Otherwise, check “m” is equal to “TRUCK”
- Set “c” is “HIGHTRUCK”
- Otherwise, set “c” is “HIGHMAIL”
- Check “m” is equal to “AIR”
- Return the value
- Check “w” is less than “MEDWT”
-
- Check “m” is equal to “AIR”
- Define the “display” method
- Display the result
- Define the “getCost” method
- Return the cost
- Define the “increaseCost” method
- Calculate the cost value
Filename: “UsePackage.java”
- Define the “UsePackage” class
- Define the main method
- Create three objects for “Package” class with different values
- Create three objects for “InsuredPackage” class with different values
- Call the “display” method with different objects of “Package” and “InsuredPackage” classes.
- Define the main method
Expert Solution & Answer

Trending nowThis is a popular solution!

Students have asked these similar questions
Parking Tickets Table
St ID L_Name ☐ F_Name Phone_No
St_Lic
Lic_No
Ticket#
Date
Code
Fine
38249
38249
82453 Green
82453 Green
82453 Green
Brown
Thomas
111-7804
FL
BRY 123
15634
10/17/06 2
$25
Brown
Thomas
111-7804
FL
BRY 123
16017
11/13/06 1
$15
Sally
391-1689
AL
TRE 141
14987
10/05/06 3
$100
Sally
391-1689
AL
Sally
391-1689
AL
TRE 141
TRE 141
16293
11/18/06 1
$15
17892
12/13/06 2
$25
The functional dependencies are:
St_ID → L_Name, F_Name, Phone_No, St_Lic, Lic_No
St_Lic → Lic_No
Code → Fine
St_ID, Ticket # → Date
1. In what normal form is the relation?|
2.
Convert PARKING TICKET to a set of 3NF relations.
In excel, What does sorting mean?
In excel, What does filtering mean?
What are three advantages of converting a range in Excel to a table and List the steps involved in creating a table in Excel if you were using the range A7:G34
Convert the relation Parking Tables to a set of 3NF relations.
Chapter 10 Solutions
Java Programming (MindTap Course List)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Please original work What is the importance of understanding both DSS models and OLAP in modern business analytics. Reflect on how the combination of these tools can enhance decision-making processes in organizations. Please cite in text references and add weblinksarrow_forwardPlease original work Talk about the role of Decision Support Systems (DSS) in business analytics. What are the major types of models used in DSS: optimization, simulation, forecasting, heuristic, and descriptive models. Talk about the relevance of these models in supporting business decisions. Please cite in text references and add weblinksarrow_forwardPlease original work What are two DSS models (e.g., optimization and forecasting). What are each model’s purpose, advantages, and limitations in the context of business analytics. Talk about some examples of how each model can be applied in real-world business scenarios, particularly in operations, marketing, or finance. Please cite in text references and add weblinksarrow_forward
- Please original work What is Online Analytical Processing (OLAP) and describe its role in DSS. Talk about how OLAP supports multidimensional analysis and decision-making in businesses. Compare how OLAP differs from traditional DSS models in terms of data processing and output. Please cite in text references and weblinksarrow_forwardPlease original work Describe the key steps involved in the modeling process: problem definition, data collection, model formulation, validation, implementation, and refinement. Talk about why each step is critical to ensuring the accuracy and reliability of the model. What are some real-world business example of a problem, and describe how the modeling process could be applied to address it using DSS. Please cite in text references and add weblinksarrow_forwardYou will be using the "usdata" package's "county" data # for this assignment. # You will need to run:# install.packages("usdata")# once to install this library - do not include the# install.packages command in your submission# as it can cause gradescope to fail ## ## ## ## ## DO NOT MODIFY BELOW ## ## ## ## ## library(usdata)county<-as.data.frame(county)county<-county[,1:14]county<-county[rowSums(is.na(county))==0,]# The set.seed command will ensure your results are consistent# each time you run the "source" commandset.seed(311)## ## ## ## ## DO NOT MODIFY ABOVE ## ## ## ## ## # Treating the "county" dataset as the population of US counties# create the dataframe "my.SRS" that represents a simple# random sample of n=250 individual counties from all counties in the US. my.SRS <- NA # Treating the "county" dataset as the population of US counties# create the dataframe "my.Stratified" that represents a stratified# sample of individual counties from all counties in…arrow_forward
- = 3. [40 pts] In the following C program ex2_2.c, we first declare and initialize an array int arr[3] {1,3,5}. Please convert the C code in main function into Assembly language. We provide the array initialization code in ex2_2_assembly.s for reference. Please complete and submit your code. ex2_2.c: #include int main() { } int arr[3] ={1,3,5}; //declare and initialize the array arr int x11 = arr[0]; int x12 = arr[1]; int x13 =x11x12; int x14 = x13 << x11; // "<<" is left shift operator arr[1] arr [2] = x13; = x14; return 0; //no need to convert this line into assembly languagearrow_forwardPlease answer JAVA OOP problem.arrow_forwardAnswer these two JAVA OOP questions.arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- EBK JAVA PROGRAMMINGComputer ScienceISBN:9781337671385Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENTMicrosoft Visual C#Computer ScienceISBN:9781337102100Author:Joyce, Farrell.Publisher:Cengage Learning,Programming Logic & Design ComprehensiveComputer ScienceISBN:9781337669405Author:FARRELLPublisher:Cengage
- C++ Programming: From Problem Analysis to Program...Computer ScienceISBN:9781337102087Author:D. S. MalikPublisher:Cengage LearningProgramming with Microsoft Visual Basic 2017Computer ScienceISBN:9781337102124Author:Diane ZakPublisher:Cengage LearningEBK JAVA PROGRAMMINGComputer ScienceISBN:9781305480537Author:FARRELLPublisher:CENGAGE LEARNING - CONSIGNMENT

EBK JAVA PROGRAMMING
Computer Science
ISBN:9781337671385
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT

Microsoft Visual C#
Computer Science
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Cengage Learning,
Programming Logic & Design Comprehensive
Computer Science
ISBN:9781337669405
Author:FARRELL
Publisher:Cengage

C++ Programming: From Problem Analysis to Program...
Computer Science
ISBN:9781337102087
Author:D. S. Malik
Publisher:Cengage Learning

Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:9781337102124
Author:Diane Zak
Publisher:Cengage Learning

EBK JAVA PROGRAMMING
Computer Science
ISBN:9781305480537
Author:FARRELL
Publisher:CENGAGE LEARNING - CONSIGNMENT
Introduction to Classes and Objects - Part 1 (Data Structures & Algorithms #3); Author: CS Dojo;https://www.youtube.com/watch?v=8yjkWGRlUmY;License: Standard YouTube License, CC-BY