Assignment 10 OOP (Animal Daycare)
Goals
?
?
?
?
Requirements
? Animal
o
? hunger
? happiness
? health
? energy
? age
? name
? species
o
? __init__
__str__
?
feed
o
? __init__
?
?
?
o
? play
?
?
?
? feed
?
?
?
? giveMedicine
?
?
?
? sleep
?
?
?
? __str__
?
?
?
?
o loadAnimals
?
? list
?
list
?
o displayMenu
?
?
?
o selectAnimal
?
?
?
?
?
o main
?
?
? list Animals loadAnimals
? while
displayMenu
?
selectAnimal Animal
Animal
?
Extra Credit
?
Sample Output Welcome to the Animal Daycare! Here is what we can do:
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 10
*Invalid selection, please try again.
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 6
Name: Ollie the Bunny
Health: 85
Happiness: 50
Hunger: 75
Energy: 60
Age: 5
********************************
Name: Murdock the French Bulldog
Health: 80
Happiness: 70
Hunger: 60
Energy: 55
Age: 3
********************************
Name: Socks the Cat
Health: 75
Happiness: 55
Hunger: 20
Energy: 70
Age: 1
********************************
Name: Peewee the Turtle
Health: 65
Happiness: 45
Hunger: 30
Energy: 15
Age: 10
********************************
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 1
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 0
Invalid input, please try again!
Please select an animal from the list (enter the 1-5): 1
You played with Ollie the Bunny!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 2
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 2
You fed Murdock the French Bulldog!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 3
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 3
You gave Socks the Cat some medicine!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 4
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 4
Peewee the Turtle took a nap!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 5
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 5
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 6
Name: Ollie the Bunny
Health: 85
Happiness: 60
Hunger: 80
Energy: 60
Age: 5
********************************
Name: Murdock the French Bulldog
Health: 80
Happiness: 70
Hunger: 50
Energy: 55
Age: 3
********************************
Name: Socks the Cat
Health: 95
Happiness: 35
Hunger: 20
Energy: 70
Age: 1
********************************
Name: Peewee the Turtle
Health: 65
Happiness: 45
Hunger: 30
Energy: 35
Age: 11
********************************
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 3
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 1
You gave Ollie the Bunny some medicine!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 5
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 1
Name: Ollie the Bunny
Health: 100
Happiness: 40
Hunger: 80
Energy: 60
Age: 5
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 7
Goodbye!
Deliverables and Submission Instructions
?
ITP115_a#_lastname_firstname
?
?
ITP115_a#_lastname_firstname.zip
?
Grading
Item Points Animal class 20
loadAnimals method 4
displayMenu method 4
selectAnimal method 4
main method 3
Total* 35
Applied Sciences
Architecture and Design
Biology
Business & Finance
Chemistry
Computer Science
Geography
Geology
Education
Engineering
English
Environmental science
Spanish
Government
History
Human Resource Management
Information Systems
Law
Literature
Mathematics
Nursing
Physics
Political Science
Psychology
Reading
Science
Social Science
Home
Homework Answers
Blog
Archive
Tags
Reviews
Contact
twitterfacebook
Copyright © 2022 SweetStudy.comSWEETSTUDY.COM YOUR HOMEWORK ANSWERS
chat0
Home.Literature.
Help.
Log in / Sign up
python assignment! need this in 5 hours!!
profile
nowneedhelp
requirement.pdf
Home>Computer Science homework help>python assignment! need this in 5 hours!!
Assignment 10 OOP (Animal Daycare)
Goals
?
?
?
?
Requirements
? Animal
o
? hunger
? happiness
? health
? energy
? age
? name
? species
o
? __init__
__str__
?
feed
o
? __init__
?
?
?
o
? play
?
?
?
? feed
?
?
?
? giveMedicine
?
?
?
? sleep
?
?
?
? __str__
?
?
?
?
o loadAnimals
?
? list
?
list
?
o displayMenu
?
?
?
o selectAnimal
?
?
?
?
?
o main
?
?
? list Animals loadAnimals
? while
displayMenu
?
selectAnimal Animal
Animal
?
Extra Credit
?
Sample Output Welcome to the Animal Daycare! Here is what we can do:
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 10
*Invalid selection, please try again.
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 6
Name: Ollie the Bunny
Health: 85
Happiness: 50
Hunger: 75
Energy: 60
Age: 5
********************************
Name: Murdock the French Bulldog
Health: 80
Happiness: 70
Hunger: 60
Energy: 55
Age: 3
********************************
Name: Socks the Cat
Health: 75
Happiness: 55
Hunger: 20
Energy: 70
Age: 1
********************************
Name: Peewee the Turtle
Health: 65
Happiness: 45
Hunger: 30
Energy: 15
Age: 10
********************************
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 1
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 0
Invalid input, please try again!
Please select an animal from the list (enter the 1-5): 1
You played with Ollie the Bunny!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 2
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 2
You fed Murdock the French Bulldog!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 3
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 3
You gave Socks the Cat some medicine!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 4
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 4
Peewee the Turtle took a nap!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 5
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 5
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 6
Name: Ollie the Bunny
Health: 85
Happiness: 60
Hunger: 80
Energy: 60
Age: 5
********************************
Name: Murdock the French Bulldog
Health: 80
Happiness: 70
Hunger: 50
Energy: 55
Age: 3
********************************
Name: Socks the Cat
Health: 95
Happiness: 35
Hunger: 20
Energy: 70
Age: 1
********************************
Name: Peewee the Turtle
Health: 65
Happiness: 45
Hunger: 30
Energy: 35
Age: 11
********************************
Name: Milo the Labrador
Health: 70
Happiness: 75
Hunger: 40
Energy: 80
Age: 6
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 3
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 1
You gave Ollie the Bunny some medicine!
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 5
1) Ollie the Bunny
2) Murdock the French Bulldog
3) Socks the Cat
4) Peewee the Turtle
5) Milo the Labrador
Please select an animal from the list (enter the 1-5): 1
Name: Ollie the Bunny
Health: 100
Happiness: 40
Hunger: 80
Energy: 60
Age: 5
********************************
1) Play
2) Feed
3) Give Medicine
4) Sleep
5) Print an Animal’s stats
6) View All Animals
7) Exit
Please make a selection: 7
Goodbye!
Deliverables and Submission Instructions
?
ITP115_a#_lastname_firstname
?
?
ITP115_a#_lastname_firstname.zip
?
Grading
Item Points Animal class 20
loadAnimals method 4
displayMenu method 4
selectAnimal method 4
main method 3
Total* 35
Applied Sciences
Architecture and Design
Biology
Business & Finance
Chemistry
Computer Science
Geography
Geology
Education
Engineering
English
Environmental science
Spanish
Government
History
Human Resource Management
Information Systems
Law
Literature
Mathematics
Nursing
Physics
Political Science
Psychology
Reading
Science
Social Science
Home
Homework Answers
Blog
Archive
Tags
Reviews
Contact
twitterfacebook
Copyright © 2022 SweetStudy.com