Question

In: Computer Science

You and your team of software developers are creating a game for children. The game has...

You and your team of software developers are creating a game for children. The game has different types of animals.

As a team of software developers, create in a 1-page Word document the class "Animal," including appropriate methods and properties that are common to all animals, subclasses of Animal, such as Cats, Dogs, and Birds, and appropriate methods and properties unique to these subclasses.

Solutions

Expert Solution

abstract class Animal {
float height;
float weight;
float energy;
string breed;

public Eat() {
energy++;
weight++;
}

public Attack() {
energy--;
weight--;
}

public void Greet() {
Console.WriteLine("Hello");
}
public void Talk() {
Console.WriteLine("Talking");
}
public virtual void Sing() {
Console.WriteLine("Singing");
}
}
class Cat: Animal {
int somethingSpecificToCat;

public Cat() {
//your constructor. initialize all fields
}
}

class Dog: Animal {
int somethingSpecificToDog;

public Dog() {
//your constructor. initialize all fields
}
}

class Birds: Animal {
int somethingSpecificToBirds;

public Birds() {
//your constructor. initialize all fields
}
}


Related Solutions

You manage a small team of developers that works on internal projects for your company. You...
You manage a small team of developers that works on internal projects for your company. You have two potential projects your team has the opportunity to work on. For the first project (Project A), your company has provided you an initial set of application features asked you to develop a cost estimate for the application. Below is some standard data on the team: Project A Description Number Number of team members 5 Developer Cost per person per day $80 Work...
Seo Yeon is a paid intern working for a small team of four software developers. Each...
Seo Yeon is a paid intern working for a small team of four software developers. Each member of the team is facing different deadlines and requires her support at different times—and all of them want to pawn their least enjoyable tasks off on her. Seo Yeon is there to learn and is happy to help out on any tasks they can give her, but she only has 40 hours per work week to offer. Identify the solution that is likely...
You are one of the developers on a team of 10 working in-house for a large...
You are one of the developers on a team of 10 working in-house for a large corporation. You've been working on a new "Press Releases" page on your company's website for a few weeks. The project involves the company's Public Relations department, and the company's Social Media team. The purpose of the page is to share the company's most recent press release, and includes a list of the company's officers, and their photos. One of those company officers, the Chief...
have you considered the risks in creating your management team? Explain.
have you considered the risks in creating your management team? Explain.
In the game console industry, game developers sell their games separately or along with the game...
In the game console industry, game developers sell their games separately or along with the game console producers. Which of the following best describe the role of game developers for game console producers? -Substitutes because game developers appropriate value from the sales of game consoles. -Partners because game developers need to customize their games to game consoles. -Complementors because games enhance the value of the game consoles. -Suppliers because game developers provide games for game consoles.
Scenario 1: You are playing soccer and your team has just finished their third game of...
Scenario 1: You are playing soccer and your team has just finished their third game of the day. The day has been very hot with temperatures in the 90s with no cloud coverage. Suddenly, one of your teammates collapses. They seem to not be fully awake and do not respond to questions you ask them. Their breathing is rapid and shallow, and they are unable to get up from the ground. Their skin is very red and hot to the...
Your company is tasked with creating software for a home security system.
1. Consider the following:Your company is tasked with creating software for a home security system. The software helps manage all the security cameras and devices installed in the house, relays communications between all parties, and provides a “dashboard” mechanism for homeowners and security personnel to access and monitor.Develop 8 to 10 requirements concerning this scenario.2. What is a “recommendation system” and how can it assist in requirements engineering? What tools can be used to assist in requirements gathering?
What are the data structures and algorithms? Why are they important to software developers? Give an...
What are the data structures and algorithms? Why are they important to software developers? Give an example of using a data structure. Give an example of using algorithm. Use Google to search for your answers. Minimum 400 words and a maximum of 1000 words.
Your legal team has approached you to work on a team to resolve a lawsuit for...
Your legal team has approached you to work on a team to resolve a lawsuit for incorrect medical coding which the patients' claim has led to higher expenses. Explain how you can use some quality tools to research the situation for legal. Provide examples of how you would apply the tools.
a) 10 children are to be divided into an A team and a B team of...
a) 10 children are to be divided into an A team and a B team of 5 each. The A team will play in one league and the B team in another. How many different divisions are possible? Answer: (10!/5!5!) b) 10 children at a playground divide themselves into two teams of 5 each. How many different divisions are possible? Answer: (10!/5!5!2!) I don't understand why in b we divide by 2!, can someone explain it in detail? It would...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT