SlideShare a Scribd company logo
1 of 2
The Barking Lot is a dog day care center that charges a weekly day care fee based on the weight
of the dog. The fee is determined as follows: $55 for dogs under 15 pounds, $75 for dogs from
15 to 30 pounds inclusive, $105 for dogs from 31 to 80 pounds inclusive, and $125 for dogs over
80 pounds.
Write pseudocode to:
a) Declare all variables and constants needed for this program
b) Allow the user to enter the dog’s weight as input
c) An if statement that determines the fee to be charged. Your if statement must work as
efficiently as possible and must not include any unnecessary tests.
d) Output a bill containing the dog’s weight as well as the weekly day care fee
Solution
pseudocode
step 1 : start
step 2 : declare day_fee=0 , weekly_fee=0
step 3 : input dog_weight
step 4 : if (dog_weight<15)
{
day_fee = dog_weight*55;
else if(15<=dog_weight<30)
{
day_fee = dog_weight*75;
}
else if(31<=dog_weight<80)
{
day_fee = dog_weight*105;
}
else
{
day_fee = dog_weight*125;
}
}
step 5 : weekly_fee=7*day_fee
step 6 : output dog_weight and weekly_fee
step 7 : stop

More Related Content

More from lmark1

The case notes that Nationwide had in mind a simple goal- but faced a.docx
The case notes that Nationwide had in mind a simple goal- but faced a.docxThe case notes that Nationwide had in mind a simple goal- but faced a.docx
The case notes that Nationwide had in mind a simple goal- but faced a.docxlmark1
 
The capital budgeting analytical technique that calculates the rate of.docx
The capital budgeting analytical technique that calculates the rate of.docxThe capital budgeting analytical technique that calculates the rate of.docx
The capital budgeting analytical technique that calculates the rate of.docxlmark1
 
The balance sheet is the cornerstone of the financial statements- The.docx
The balance sheet is the cornerstone of the financial statements- The.docxThe balance sheet is the cornerstone of the financial statements- The.docx
The balance sheet is the cornerstone of the financial statements- The.docxlmark1
 
The capital account balances for Donald & Hanes LLP on January 1- 2011.docx
The capital account balances for Donald & Hanes LLP on January 1- 2011.docxThe capital account balances for Donald & Hanes LLP on January 1- 2011.docx
The capital account balances for Donald & Hanes LLP on January 1- 2011.docxlmark1
 
the bookkeeper of vitial inc has asked to assist him with preparation.docx
the bookkeeper of vitial inc has asked to assist him with preparation.docxthe bookkeeper of vitial inc has asked to assist him with preparation.docx
the bookkeeper of vitial inc has asked to assist him with preparation.docxlmark1
 
The balanced scorecard integrates financial and nonfinancial measures.docx
The balanced scorecard integrates financial and nonfinancial measures.docxThe balanced scorecard integrates financial and nonfinancial measures.docx
The balanced scorecard integrates financial and nonfinancial measures.docxlmark1
 
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docx
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docxThe balance sheet for the partnership of Nina- Pinta- and Santa Maria.docx
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docxlmark1
 
Palindromes A palindrome is a word or phrase that reads the same backw (1).docx
Palindromes A palindrome is a word or phrase that reads the same backw (1).docxPalindromes A palindrome is a word or phrase that reads the same backw (1).docx
Palindromes A palindrome is a word or phrase that reads the same backw (1).docxlmark1
 
Palindromes A palindrome is a word or phrase that reads the same backw (2).docx
Palindromes A palindrome is a word or phrase that reads the same backw (2).docxPalindromes A palindrome is a word or phrase that reads the same backw (2).docx
Palindromes A palindrome is a word or phrase that reads the same backw (2).docxlmark1
 
Palindromes A palindrome is a word or phrase that reads the same backw.docx
Palindromes A palindrome is a word or phrase that reads the same backw.docxPalindromes A palindrome is a word or phrase that reads the same backw.docx
Palindromes A palindrome is a word or phrase that reads the same backw.docxlmark1
 
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docx
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docxPAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docx
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docxlmark1
 
P5- Use the financial information below to calculate and interpret the.docx
P5- Use the financial information below to calculate and interpret the.docxP5- Use the financial information below to calculate and interpret the.docx
P5- Use the financial information below to calculate and interpret the.docxlmark1
 
Pablo own small transportation firm in Latvia- His trucks delivers goo.docx
Pablo own small transportation firm in Latvia- His trucks delivers goo.docxPablo own small transportation firm in Latvia- His trucks delivers goo.docx
Pablo own small transportation firm in Latvia- His trucks delivers goo.docxlmark1
 
Over the past weeks we have been examining the inference process- big.docx
Over the past weeks we have been examining the inference process- big.docxOver the past weeks we have been examining the inference process- big.docx
Over the past weeks we have been examining the inference process- big.docxlmark1
 
Outline the role of the operating system and identify the features of.docx
Outline the role of the operating system and identify the features of.docxOutline the role of the operating system and identify the features of.docx
Outline the role of the operating system and identify the features of.docxlmark1
 
Outline the key issues involved in Open Systems Theory including the f.docx
Outline the key issues involved in Open Systems Theory including the f.docxOutline the key issues involved in Open Systems Theory including the f.docx
Outline the key issues involved in Open Systems Theory including the f.docxlmark1
 
Out of the following- which are non separately stated for Neely Inc--.docx
Out of the following- which are non separately stated for Neely Inc--.docxOut of the following- which are non separately stated for Neely Inc--.docx
Out of the following- which are non separately stated for Neely Inc--.docxlmark1
 
ou shoot a beam of electrons through a double slit to make an interfer.docx
ou shoot a beam of electrons through a double slit to make an interfer.docxou shoot a beam of electrons through a double slit to make an interfer.docx
ou shoot a beam of electrons through a double slit to make an interfer.docxlmark1
 
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docx
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docxOS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docx
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docxlmark1
 
Organizational Structure Evaluate the decision-making process and its.docx
Organizational Structure Evaluate the decision-making process and its.docxOrganizational Structure Evaluate the decision-making process and its.docx
Organizational Structure Evaluate the decision-making process and its.docxlmark1
 

More from lmark1 (20)

The case notes that Nationwide had in mind a simple goal- but faced a.docx
The case notes that Nationwide had in mind a simple goal- but faced a.docxThe case notes that Nationwide had in mind a simple goal- but faced a.docx
The case notes that Nationwide had in mind a simple goal- but faced a.docx
 
The capital budgeting analytical technique that calculates the rate of.docx
The capital budgeting analytical technique that calculates the rate of.docxThe capital budgeting analytical technique that calculates the rate of.docx
The capital budgeting analytical technique that calculates the rate of.docx
 
The balance sheet is the cornerstone of the financial statements- The.docx
The balance sheet is the cornerstone of the financial statements- The.docxThe balance sheet is the cornerstone of the financial statements- The.docx
The balance sheet is the cornerstone of the financial statements- The.docx
 
The capital account balances for Donald & Hanes LLP on January 1- 2011.docx
The capital account balances for Donald & Hanes LLP on January 1- 2011.docxThe capital account balances for Donald & Hanes LLP on January 1- 2011.docx
The capital account balances for Donald & Hanes LLP on January 1- 2011.docx
 
the bookkeeper of vitial inc has asked to assist him with preparation.docx
the bookkeeper of vitial inc has asked to assist him with preparation.docxthe bookkeeper of vitial inc has asked to assist him with preparation.docx
the bookkeeper of vitial inc has asked to assist him with preparation.docx
 
The balanced scorecard integrates financial and nonfinancial measures.docx
The balanced scorecard integrates financial and nonfinancial measures.docxThe balanced scorecard integrates financial and nonfinancial measures.docx
The balanced scorecard integrates financial and nonfinancial measures.docx
 
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docx
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docxThe balance sheet for the partnership of Nina- Pinta- and Santa Maria.docx
The balance sheet for the partnership of Nina- Pinta- and Santa Maria.docx
 
Palindromes A palindrome is a word or phrase that reads the same backw (1).docx
Palindromes A palindrome is a word or phrase that reads the same backw (1).docxPalindromes A palindrome is a word or phrase that reads the same backw (1).docx
Palindromes A palindrome is a word or phrase that reads the same backw (1).docx
 
Palindromes A palindrome is a word or phrase that reads the same backw (2).docx
Palindromes A palindrome is a word or phrase that reads the same backw (2).docxPalindromes A palindrome is a word or phrase that reads the same backw (2).docx
Palindromes A palindrome is a word or phrase that reads the same backw (2).docx
 
Palindromes A palindrome is a word or phrase that reads the same backw.docx
Palindromes A palindrome is a word or phrase that reads the same backw.docxPalindromes A palindrome is a word or phrase that reads the same backw.docx
Palindromes A palindrome is a word or phrase that reads the same backw.docx
 
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docx
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docxPAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docx
PAD601 Comment in detail on the events of each date 1880- 1881- 1883-.docx
 
P5- Use the financial information below to calculate and interpret the.docx
P5- Use the financial information below to calculate and interpret the.docxP5- Use the financial information below to calculate and interpret the.docx
P5- Use the financial information below to calculate and interpret the.docx
 
Pablo own small transportation firm in Latvia- His trucks delivers goo.docx
Pablo own small transportation firm in Latvia- His trucks delivers goo.docxPablo own small transportation firm in Latvia- His trucks delivers goo.docx
Pablo own small transportation firm in Latvia- His trucks delivers goo.docx
 
Over the past weeks we have been examining the inference process- big.docx
Over the past weeks we have been examining the inference process- big.docxOver the past weeks we have been examining the inference process- big.docx
Over the past weeks we have been examining the inference process- big.docx
 
Outline the role of the operating system and identify the features of.docx
Outline the role of the operating system and identify the features of.docxOutline the role of the operating system and identify the features of.docx
Outline the role of the operating system and identify the features of.docx
 
Outline the key issues involved in Open Systems Theory including the f.docx
Outline the key issues involved in Open Systems Theory including the f.docxOutline the key issues involved in Open Systems Theory including the f.docx
Outline the key issues involved in Open Systems Theory including the f.docx
 
Out of the following- which are non separately stated for Neely Inc--.docx
Out of the following- which are non separately stated for Neely Inc--.docxOut of the following- which are non separately stated for Neely Inc--.docx
Out of the following- which are non separately stated for Neely Inc--.docx
 
ou shoot a beam of electrons through a double slit to make an interfer.docx
ou shoot a beam of electrons through a double slit to make an interfer.docxou shoot a beam of electrons through a double slit to make an interfer.docx
ou shoot a beam of electrons through a double slit to make an interfer.docx
 
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docx
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docxOS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docx
OS (a) - 5 Points - What is an inode- (b) - 5 Points - How does a soft.docx
 
Organizational Structure Evaluate the decision-making process and its.docx
Organizational Structure Evaluate the decision-making process and its.docxOrganizational Structure Evaluate the decision-making process and its.docx
Organizational Structure Evaluate the decision-making process and its.docx
 

Recently uploaded

Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designMIPLM
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Celine George
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4MiaBumagat1
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomnelietumpap1
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONHumphrey A Beña
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17Celine George
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITY
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITYISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITY
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITYKayeClaireEstoconing
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptxSherlyMaeNeri
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)lakshayb543
 
Science 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxScience 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxMaryGraceBautista27
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxAshokKarra1
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptxmary850239
 
Q4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxQ4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxnelietumpap1
 

Recently uploaded (20)

Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-design
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4
 
ENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choomENGLISH6-Q4-W3.pptxqurter our high choom
ENGLISH6-Q4-W3.pptxqurter our high choom
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITY
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITYISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITY
ISYU TUNGKOL SA SEKSWLADIDA (ISSUE ABOUT SEXUALITY
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
Visit to a blind student's school🧑‍🦯🧑‍🦯(community medicine)
 
Science 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptxScience 7 Quarter 4 Module 2: Natural Resources.pptx
Science 7 Quarter 4 Module 2: Natural Resources.pptx
 
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptxYOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptx
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx4.18.24 Movement Legacies, Reflection, and Review.pptx
4.18.24 Movement Legacies, Reflection, and Review.pptx
 
Q4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxQ4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptx
 

The Barking Lot is a dog day care center that charges a weekly day car.docx

  • 1. The Barking Lot is a dog day care center that charges a weekly day care fee based on the weight of the dog. The fee is determined as follows: $55 for dogs under 15 pounds, $75 for dogs from 15 to 30 pounds inclusive, $105 for dogs from 31 to 80 pounds inclusive, and $125 for dogs over 80 pounds. Write pseudocode to: a) Declare all variables and constants needed for this program b) Allow the user to enter the dog’s weight as input c) An if statement that determines the fee to be charged. Your if statement must work as efficiently as possible and must not include any unnecessary tests. d) Output a bill containing the dog’s weight as well as the weekly day care fee Solution pseudocode step 1 : start step 2 : declare day_fee=0 , weekly_fee=0 step 3 : input dog_weight step 4 : if (dog_weight<15) { day_fee = dog_weight*55; else if(15<=dog_weight<30) { day_fee = dog_weight*75; } else if(31<=dog_weight<80) { day_fee = dog_weight*105; } else
  • 2. { day_fee = dog_weight*125; } } step 5 : weekly_fee=7*day_fee step 6 : output dog_weight and weekly_fee step 7 : stop