The base class Pet has attributes name and age. The derived class Dog inherits attributes from the base class Pet class and includes a breed attribute. Complete the program to:

Create a generic pet, and print the pet's information using print_info().
Create a Dog pet, use print_info() to print the dog's information, and add a statement to print the dog's breed attribute.
Ex: If the input is:

Dobby
2
Kreacher
3
German Schnauzer
the output is:

Pet Information:
Name: Dobby
Age: 2
Pet Information:
Name: Kreacher
Age: 3
Breed: German Schnauzer

code-
class Pet:
def __init__(self):
self.name = ''
self.age = 0

def print_info(self):
print('Pet Information:')
print(' Name:', self.name)
print(' Age:', self.age)

class Dog(Pet):
def __init__(self):
Pet.__init__(self)
self.breed = ''

my_pet = Pet()
my_dog = Dog()

pet_name = input()
pet_age = int(input())
dog_name = input()
dog_age = int(input())
dog_breed = input()

# TODO: Create generic pet (using pet_name, pet_age) and then call print_info()

# TODO: Create dog pet (using dog_name, dog_age, dog_breed) and then call print_info()

# TODO: Use my_dog.breed to output the breed of the dog

Answers

Answer 1

Here's the complete code with the TODOs filled in:

The Code

class Pet:

def init(self):

self.name = ''

self.age = 0

def print_info(self):

   print('Pet Information:')

   print(' Name:', self.name)

   print(' Age:', self.age)

class Dog(Pet):

def init(self):

Pet.init(self)

self.breed = ''

pet_name = input()

pet_age = int(input())

dog_name = input()

dog_age = int(input())

dog_breed = input()

my_pet = Pet()

my_pet.name = pet_name

my_pet.age = pet_age

my_pet.print_info()

my_dog = Dog()

my_dog.name = dog_name

my_dog.age = dog_age

my_dog.breed = dog_breed

my_dog.print_info()

print('Breed:', my_dog.breed)

Sample Input:

Dobby

2

Kreacher

3

German Schnauzer

Sample Output:

Pet Information:

Name: Dobby

Age: 2

Pet Information:

Name: Kreacher

Age: 3

Breed: German Schnauzer

Read more about programs here:

https://brainly.com/question/26134656
#SPJ1


Related Questions

Agriscience in the United States?

Answers

Answer:

The history of agriculture in the United States covers the period from the first English settlers to the present day. In Colonial America, agriculture was the primary livelihood for 90% of the population, and most towns were shipping points for the export of agricultural products. Most farms were geared toward subsistence production for family use. The rapid growth of population and the expansion of the frontier opened up large numbers of new farms, and clearing the land was a major preoccupation of farmers. After 1800, cotton became the chief crop in southern plantations, and the chief American export. After 1840, industrialization and urbanization opened up lucrative domestic markets. The number of farms grew from 1.4 million in 1850, to 4.0 million in 1880, and 6.4 million in 1910; then started to fall, dropping to 5.6 million in 1950 and 2.2 million in 2008

Explanation:

A structure that organizes data in a list that is commonly 1-dimensional or 2-
dimensional
Linear Section
Constant
No answertet provided
It intro technology

Answers

Answer:

An array.

Explanation:

An array can be defined as a structure that organizes data in a list that is commonly 1-dimensional or 2-dimensional.

Simply stated, an array refers to a set of memory locations (data structure) that comprises of a group of elements with each memory location sharing the same name. Therefore, the elements contained in array are all of the same data type e.g strings or integers.

Basically, in computer programming, arrays are typically used by software developers to organize data, in order to search or sort them.

Binary search is an efficient algorithm used to find an item from a sorted list of items by using the run-time complexity of Ο(log n), where n is total number of elements. Binary search applies the principles of divide and conquer.

In order to do a binary search on an array, the array must first be sorted in an ascending order.

Hence, array elements are mainly stored in contiguous memory locations on computer.

Use the drop-down menus to describe how to add a data bar to a report.
1. Open the table in view.
2. Click the column of the desired numerical field.
3. Click the conditional tab Format, then .
4. In the Rules Manager dialog box, click .
5. Select to “compare to other records,” and determine whether you want the value and bar to show at the same time.
6. Adjust the desired length of the bar and the color. Click OK.
7. Once satisfied with your rule, click and then OK.

Answers

Answer:

1. layout

3. conditional formatting

4. new rule

7. apply

Explanation:

just did it on edge

Arrange the computers in the order fastest to slowest: Minicomputer, Supercomputer, Personal Computer and Mainframe.

Answers

Answer:

supercomputer, mainframe, personal computer, minicomputer

Explanation:

How many outcomes are possible in this control structure?
forever
if
is A button pressed then
set background image to
else
set background image to

Answers

Answer:

In the given control structure, there are two possible outcomes:

1) If the condition "Is A button pressed?" evaluates to true, then the background image will be set to a specific value.

2) If the condition "Is A button pressed?" evaluates to false, then the background image will be set to another value.

Therefore, there are two possible outcomes in this control structure.

Hope this helps!

Just press a to set up your background

C++
Create an array of six numbers which have the data type
of double. Include the array in a program which asks the
user for six numbers and assigns the numbers to the
elements in the array. Use a for loop to input the
numbers as well as output the values in the array.

Answers

Here is a code snippet for the array of six numbers:

#include <iostream>

using namespace std;

int main() {

   const int ARRAY_SIZE = 6; // Define the size of the array

   double myArray[ARRAY_SIZE]; // Create an array of double numbers

   // Use a for loop to get input from the user and assign values to the array

   for (int i = 0; i < ARRAY_SIZE; i++) {

       cout << "Enter a number: ";

       cin >> myArray[i];

   }

   // Use a for loop to output the array values

   cout << "The array contains: ";

   for (int i = 0; i < ARRAY_SIZE; i++) {

       cout << myArray[i] << " ";

   }

   cout << endl;

   return 0;

}

Ensure you read the comment to grasp it well enough.

Understanding C++

C++ is a general-purpose programming language that was developed in the 1980s as an extension of the C programming language.

It is a high-level language that allows programmers to write efficient, portable, and reusable code.

C++ is an object-oriented programming (OOP) language, which means that it uses the concepts of objects and classes to organize code and data.

Learn more about coding here:

https://brainly.com/question/27639923

#SPJ1

The following do-while loop is suppose to ask for the price for a gallon of gas. The price must a positive number. The price can be an integer value or a double value. for example the price can be 3 or 3.0 or 3.5.

To create a robust program, we must do the data validation and as long as the user is entering a negative value or a String, the program must keep asking the user to enter a valid input.

in this program you need to use some of the scanner methods listed here, make sure to use the proper ones: hasNextInt(), hasNextDouble(), hasNextLine(), hasNext(), nextInt(), nextDouble(), nextLine()

Must flush the buffer at the proper locations in the code

Answers

Answer:

import java.util.Scanner;

public class qs {

   public static void main(String[] args) {

       Scanner input = new Scanner(System.in);

       double price;

       do {

           System.out.print("Enter the price for a gallon of gas: ");

           while (!input.hasNextDouble()) {

               System.out.println("That's not a number!");

               input.next(); // this is important!

           }

           price = input.nextDouble();

       } while (price < 0);

       System.out.println("The price is " + price);

   }

}

Assume the variable s is a String and index is an int. Write an if-else statement that assigns 100 to index if the value of s would come between "mortgage" and "mortuary" in the dictionary. Otherwise, assign 0 to index.

Answers

Using the knowledge in computational language in python it is possible to write a code that Assume the variable s is a String and index is an int.

Writting the code:

Assume the variable s is a String

and index is an int

an if-else statement that assigns 100 to index

if the value of s would come between "mortgage" and "mortuary" in the dictionary

Otherwise, assign 0 to index

is

if(s.compareTo("mortgage")>0 && s.compareTo("mortuary")<0)

{

   index = 100;

}

else

{

   index = 0;

}

See more about JAVA at brainly.com/question/12975450

#SPJ1

Assume the variable s is a String and index is an int. Write an if-else statement that assigns 100 to

Give the CSS code required to make the entire web page shown in Figure 2 (on the following page). You are to label your answers using the form 4a), 4b), 4c) etc. The design requirements are as follows:
a. The page should full the entire screen. [1]
b. The body should have no margins or padding. [1]
c. The left and right sidebars must be positioned appropriately. [2]
d. The navigation bar section must have the following properties [1]
i. Occupy seven percent (7%) of the page height.
ii. Background color #581845
e. The navigation links in the header must have the following properties: [4]
i. Georgia font
ii. Bold
iii. Centered
iv. White text color
v. Set bottom border to solid when hovered over
f. The area between the navigation section and the footer must be eighty-six percent (86%) of
the page height. [I]
g. The footer section must have the following properties: [1]
i. Occupy seven percent (7%) of the screen height.
ii. Text should be white in color.
h. Any link on the page, when hovered over must change its background color to #C70039.
[1]
i. Any link on the page, when active, must change its background color to #FFC300. [1]
j. Both sidebars must have a background color of #FCEFF1 [1]
k. The left-sidebar must have the following properties: [1]
i. Links must have a text color of #FF5733.
ii. Change link text color to white when hovered over

Give the CSS code required to make the entire web page shown in Figure 2 (on the following page). You

Answers

Answer:

Here is the CSS code that would fulfill the design requirements for the web page described:

4a)

html, body {

   height: 100%;

   width: 100%;

   margin: 0;

   padding: 0;

}

4b)

body {

   margin: 0;

   padding: 0;

}

4c)

.left-sidebar, .right-sidebar {

   position: absolute;

   height: 100%;

}

.left-sidebar {

   left: 0;

}

.right-sidebar {

   right: 0;

}

4d)

.navigation-bar {

   height: 7%;

   background-color: #581845;

}

4e)

.navigation-bar a {

   font-family: Georgia;

   font-weight: bold;

   text-align: center;

   color: white;

}

.navigation-bar a:hover {

   border-bottom: solid;

}

4f)

.main-content {

   height: 86%;

}

4g)

.footer {

   height: 7%;

   color: white;

}

4h)

a:hover {

   background-color: #C70039;

}

4i)

a:active {

   background-color: #FFC300;

}

4j)

.left-sidebar, .right-sidebar {

   background-color: #FCEFF1;

}

4k)

.left-sidebar a {

   color: #FF5733;

}

.left-sidebar a:hover {

   color: white;

}

Explanation:

Note that this CSS code assumes that the left sidebar has a class of "left-sidebar", the right sidebar has a class of "right-sidebar", the navigation bar has a class of "navigation-bar", the main content area has a class of "main-content", and the footer has a class of "footer". You will need to add these classes to the relevant elements in your HTML code for the CSS styles to be applied.

what is the internal representation of -531?

Answers

The internal representation of -531 can vary depending on the underlying computer architecture and the data type used to store the number. However, a common representation for negative integers in binary computer systems is Two's Complement representation. In Two's Complement representation, the most significant bit is used to indicate the sign of the number, with 0 indicating positive and 1 indicating negative. The magnitude of the number is stored in the remaining bits.

Backing up and synchronization are the same thing.

A.)True
B.) False​

Answers

Answer: A.)true

Explanation: This is true for a number of reasons, the first being that synced files

100pts!!!! It can be challenging to create algorithms that are not biased towards minority groups because machine learning works by _____. Select 2 options.


1. discarding outliers

2. excluding majorities

3. including outliers

4. discarding patterns

5. determining patterns

Answers

100pts!!!! It can be challenging to create algorithms that are not biased towards minority groups because machine learning works by _____. Select 2 options.


1. discarding outliers

2. excluding majorities

3. including outliers

4. discarding patterns

5. determining patterns

the company has finished designing a software program but users aren't sure how to use it​

Answers

Answer:

The company should go back into the company and make it a little more easier to use or the company should put out an announcement or something so the people trying to use it know how

Explanation:

Mark me the brainliest please and rate me

Answer:

Several people in the human resources department need new software installed. An employee has an idea for a software program that can save the company time, but doesn't know how to write it.

Explanation:

Difference between entropy and enthalpy is

Answers

Answer:

Explanation:

Enthalpy is the measure of total heat present in the thermodynamic system where the pressure is constant. Entropy is the measure of disorder in a thermodynamic system.

Juan has performed a search on his inbox and would like to ensure that the results only include those items with
attachments which command group will he use?
O Scope
O Results
O Refine
Ο Ορtions

Answers

Answer:

The Refine command group

Explanation:

There can be multiple answers.

There can be multiple answers.

Answers

In computer terminology, Functional Specification refers to

"The technical and special requirements" (Option B)

When performing stress testing, the system is tested for resistance to unforeseen situations. (Option C)

The Input data set that on which the program should be tested is "on acceptable and unacceptable y functional specification. (Option C)

What is Functional Specifications?

In systems engineering and software development, a functional specification is a document that outlines the functions that a system or component must accomplish. The documentation often defines what the system user requires as well as the expected attributes of inputs and outputs.

Company information, start date, list of services, product purpose, audience, organization, how it operates, competition, and budget/deadline are examples of functional requirements. Context, user needs, a data flow diagram, and a logical data model are all possible.

In each firm or organization, the specific individual or group whose duty it is to write a functional specification may change, although it is seldom authored by a single person.

Typically, a product manager creates functional specification papers in collaboration with others, such as UXers, clients, and other project stakeholders.

Learn more about Functional requirements:
https://brainly.com/question/27903805
#SPJ1

PAssignment explanation
In this assignment, you need to implement a Python program using a function that takes the expression as
parameter and return the results.
1. Implements a calculator with the following functionality:
O
Can support the following operations: +- ***/ // %.
O
Do the math and find the result using the PEMDAS rules learned in the lecture and in high
school calculus
O Supports both integers and floats and returns the result in float format with a
precision of 2 decimal places.
2. The program does NOT ask the user for inputs one after another! Rather, it asks the user to enter
a string containing the entire mathematical operation he/she wishes to perform as follows:
Calculator:
User:
Please enter the mathematical expression you want the program to evaluate:
2.5 +3-10/4 **3 // 2 +99.1-9% 3
3. Once user finishes the calculation, the calculator should ask the user if he has more operations to
do or not.
4. If the user is done with calculations, the calculator should give a summary of the all the operations
done in this calculation session along with the output results as follows:
|Operation no. |
|1
12
|3
I
1
CALCULATOR OPERATIONS HISTORY
1
2.5 +3-10/4 ** 3 // 2 +99.1-9% 3 |
98.1/3 +9-3.3 ** 2 +44
100 * 9+3** 8/9
operation expression
1
operation output |
104.6
74.81
1629.0
NOTE: the data above is JUST an example, your code MUST accept user input for different strings that
follow the format mentioned in step 2 and successfully do the extraction and display of the output in a
similar way to what is shown in step 4. The grader will enter different inputs to test your code to assure
its success in accomplishing the assignment objective.
IMPORTANT: you are NOT allowed to use any Python built-in (or even available online)
module function that performs the above requirement, such as eval or similar. You MUST do
it yourself PYTHON PROGRAM

Answers

Answer:

yes

Explanation:

program using a function that takes the expression as

parameter and return the results.

1. Implements a calculator with the following functionality:

O

Can support the following operations: +- ***/ // %.

O

Do the math and find the result using the PEMDAS rules learned in the lecture and in high

school calculus

O Supports both integers and floats and returns the result in float format with a

precision of 2 decimal places.

2. The program does NOT ask the user for inputs one after another! Rather, it asks the user to enter

a string containing the entire mathematical operation he/she wishes to perform as follows:

Calculator:

User:

Please enter the mathematical expression you want the program to evaluate:

2.5 +3-10/4 **3 // 2 +99.1-9% 3

3. Once user finishes the calculation, the calculator should ask the user if he has more operations to

do or not.

4. If the user is done with calculations, the calculator should give a summary of the all the operations

done in this calculation session along with the output results as follows:

|Operation no. |

|1

12

|3

I

1

CALCULATOR OPERATIONS HISTORY

1

2.5 +3-10/4 ** 3 // 2 +99.1-9% 3 |

98.1/3 +9-3.3 ** 2 +44

100 * 9+3** 8/9

operation expression

1

operation output |

104.6

74.81

1629.0

NOTE: the data above is JUST an example, your code MUST accept user input for different strings that

follow the format mentioned in step 2 and successfully do the extraction and display of the output in a

similar way to what is shown in step 4. The grader will enter different inputs to test your code to assure

its success in accomplishing the assignment objective.

IMPORTANT: you are NOT allowed to use any Python built-in (or even available online)

module function that performs the above requirement, such as eval or similar. You MUST do

it yourself PYTHON PROGRAM

....................

Answers

Answer:

What s this question about?

Explanation:

I will edit my answer but i need to understand what you want me to write about.

You are required to design the network for a institute, what are the aspects that you take into consideration? in relation to the network layer and transportation layer.

Answers

When designing a network for an institute, there are several key aspects that I would take into consideration, both at the network layer and the transport layer.

At the network layer, I would focus on ensuring that the network is able to support the necessary number of devices and users, and that it is able to handle the expected amount of traffic. This would involve choosing the appropriate network architecture, such as a star, bus, or mesh, and determining the optimal placement of network devices such as routers, switches, and hubs.

At the transport layer, I would focus on ensuring that the network is able to provide reliable and efficient communication between devices. This would involve choosing the appropriate transport protocol, such as TCP or UDP, and configuring it to provide the necessary level of reliability and performance. I would also need to consider factors such as network congestion, packet loss, and error correction, to ensure that the network is able to provide a high quality of service to all users.

In general, my goal in designing the network for the institute would be to ensure that it is able to support the needs of the users and devices, and to provide a reliable and efficient means of communication

Which of the following is NOT a reason to include comments in programs?

a. Comments help the computer decide whether certain components of a program
are important.

b .Comments help programmers debug issues in their own code

c. Comments help document how code was written for other programmers to use

d. Comments enable programmers to track their work throughout the development
process

Answers

Answer:

A Would be correct!

Explanation:

The reason for this is because in a code when you use the comment out the compiler will skip over it and will not do anything and will skip it. So the comment can help the computer do anything!

HOPE THIS HELPED MAKE ME THE BRAINLIST!

Using programming concepts, the option that is NOT a reason to include comments in a code is:

a. Comments help the computer decide whether certain components of a program  are important.

-------------------------

Usually, codes are very long, and each person is responsible for a part of the problem. The parts have to be intervened with each other, and thus, sometimes a programmer will have to look at another part of the code, not coded by him. Thus, for the programmer and other people working in the project to understand, comments are important.Additionally, the comments are used to help the programmers debug their own code, as they can go part by part and see what is done in each part, also helping them work throughout the development process.In a program, there may be some components that end up not being necessary, but this is not decided by comments, and thus, option A is not a reason to include comments in programs.

A similar problem is given at https://brainly.com/question/13527834

FILL IN THE BLANK 1. The people, procedures, hardware, software, data, and knowledge needed to develop computer systems and machines that can simulate human intelligence process include _____________, _______________, and _______________. a. learning, reasoning, self-correction b. learning, discipline, self-awareness c. reasoning, self-awareness, self-correction d. learning, reasoning, self-awareness

Answers

The word "information system" refers to a system that consists of hardware, software, data, people, and procedures and that communicates with one another to produce information.

What are some instances of an information system?

Systems for gathering, processing, storing, and disseminating information are collections of various information resources (such as software, hardware, connections between computers, the system housing, system users, and computer system information).

What function does an information system serve?

Users of information systems can gather, store, organize, and distribute data—tasks that can be useful for businesses for a number of reasons. Information systems are used by many firms to manage resources and boost productivity. In order to compete in international markets, some people rely on information systems.

To know more about information system visit;

https://brainly.com/question/28945047

#SPJ4

Description:
Read integer inCount from input as the number of integers to be read next. Use a loop to read the remaining integers from input. Output all integers on the same line, and surround each integer with curly braces. Lastly, end with a newline.

Ex: If the input is:

2
55 75
then the output is:

{55}{75}

Code:
#include
using namespace std;

int main() {
int inCount;

return 0;
}

Description:Read integer inCount from input as the number of integers to be read next. Use a loop to

Answers

Here's the modified code that includes the requested functionality:

#include <iostream>

using namespace std;

int main() {

   int inCount;

   cin >> inCount;

   for (int i = 0; i < inCount; i++) {

       int num;

       cin >> num;

       cout << "{" << num << "}"; }

  cout << "\n";

   return 0;}

In this code, we first read the integer inCount from the input, which represents the number of integers to be read next. Then, using a loop, we read each of the remaining integers from the input and output them surrounded by curly braces {}. Finally, we print a newline character to end the line of output.

Learn more about integer loop, here:

https://brainly.com/question/31493384

#SPJ1

Write the algorithmic description& draw a flow chart to find product of the first 10 counting numbers​

Answers

Answer:

n!

\(p = 1 \\ for \: n = 1 \: to \: 10 \: step \: 1 \\ p = p*n \\ next \\ print \: p\)

what number am i. i am less than 10 i am not a multiple of 2 i am a coposite

Answers

Answer: 9 is less than 10, it is odd (not a multiple of 2), and it is composite (since it has factors other than 1 and itself, namely 3). Therefore, the answer is 9.

The answer is nine because if you write all the numbers that are under ten you can see that 2, 4, 6, and, 8 are multiples of 2 so you can’t do that so then you gotta see which ones are composite which is nine because 1, 5, and 7 don’t have any more factors than for example 7 and 1.

The DNS converts ____ into an IP address.

Answers

Answer:

DNS converts human readable domain names to an IP adress.

Explanation:

You have a meeting this morning where you and your work group will determine exactly which features a software project will have. Which part of the software development life cycle does this describe? A. Analysis B. Development C. Implementation D. Design​

Answers

A. You are analyzing the way the software should run and what’s it’s purpose is. I would also believe that D. May be the answer but design more closely means the design of the software and not the planning stage.

The phase of the software development life cycle that this scenario describe is: D. Design​.

What is software development life cycle?

Software development life cycle (SDLC) can be defined as a strategic methodology that defines the key steps, phases, or stages for the design, development and implementation of high quality software programs (applications).

Generally, there are six (6) main steps involved in the development of a software program and these include;

PlanningAnalysisDesignDevelopment (coding)DeploymentMaintenance

In this scenario, you and your work group are in the design phase of the software development life cycle (SDLC).

Read more on software here: brainly.com/question/26324021

3
Drag each label to the correct location on the image.
Pauline has decided that she wants to work in public relations, but she wants to work in the nonprofit sector. Help her decide which organizations to
shortlist by categorizing the organizations as commercial or nonprofit
All rights reserved
hotels
restaurants convention and visitors bureaus
information kiosks
Commercial Sector
airlines travel agencies
Nonprofit Sector

Answers

To categorize the organizations as commercial or nonprofit for Pauline's shortlisting in the public relations field, we can place the labels accordingly:

Commercial Sector:

- hotels

- restaurants

- convention and visitors bureaus

- information kiosks

- airlines

- travel agencies

Nonprofit Sector:

- All rights reserved

In the commercial sector, hotels, restaurants, convention and visitors bureaus, information kiosks, airlines, and travel agencies are profit-oriented businesses that operate in various industries. These organizations aim to generate revenue and maximize profitability through their products or services.

On the other hand, the label "All rights reserved" suggests an indication of copyright ownership or intellectual property protection, which is not directly related to a specific sector or organization type. Therefore, it does not fall into either the commercial or nonprofit sector category.

In Pauline's case, as she wants to work in public relations within the nonprofit sector, she should focus on shortlisting organizations that fall under the nonprofit sector. These could include charitable organizations, foundations, non-governmental organizations (NGOs), advocacy groups, or community-based organizations that operate with a mission to serve the public good rather than pursuing profits.

By categorizing organizations as commercial or nonprofit, Pauline can streamline her job search and target her efforts towards the specific sector that aligns with her career goals in public relations within the nonprofit realm.

For more such questions on commercial, click on:

https://brainly.com/question/1432446

#SPJ8

Cmu cs academy unit 4 flying fish


Does someone have the answers for 4.3.3 flying fish in cmu cs academy explore programming (cs0)? I'm stuck on it

Answers

The code you provided tells that the fish should be hooked when the mouse is close enough to the fish and below the water, with the following condition:

python

elif (mouseY > 300):

However, this condition alone may not be enough to properly hook the fish. You may need to adjust the condition or add additional conditions to ensure that the fish is being hooked correctly.

What is the Python code about?

Based on the code you provided, it seems like you have implemented some restrictions for moving the fishing line and hooking the fish. If the fish is too far from the boat, you only move the fishing line. If the mouse is too far from the fish, you only move the line. If the mouse is close enough to the fish and below the water, the line should hook the fish.

However, it's hard to tell what specific issue you are facing without more context or a more detailed description of the problem. One thing to check is the values you are using to determine if the fish is close enough to be hooked. You mentioned that the horizontal distance between the mouse and the fish should be no more than 80, but your code checks if the mouse is less than 260. If this value is incorrect, it could be preventing the fish from being hooked.

Therefore, Another thing to check is the order in which you are updating the position of the fish and the fishing line

Read more about Python coding here:

https://brainly.com/question/26497128

#SPJ1

See full text below

cs cmu academy unit 4.4 fishing need help on homework

[Python]

app.background = gradient('lightSkyBlue', 'orange', start='top')

# sun and lake

Circle(250, 335, 50, fill='gold')

Rect(0, 300, 400, 100, fill='dodgerBlue')

# boat and fishing rod

Polygon(0, 270, 0, 350, 50, 350, 85, 315, 100, 270, fill='sienna')

Line(0, 240, 140, 160)

# fishing line, fish body, and fish tail

fishingLine = Line(140, 160, 140, 340, lineWidth=1)

fishBody = Oval(340, 340, 50, 30, fill='salmon')

fishTail = Polygon(350, 340, 380, 350, 380, 330, fill='salmon')

def pullUpFish():

fishingLine.x2 = 140

fishingLine.y2 = 225

fishBody.rotateAngle = 90

fishBody.centerX = 140

fishBody.centerY = 250

fishTail.rotateAngle = 90

fishTail.centerX = 140

fishTail.top = 255

def onKeyPress(key):

# Release the fish if the correct key is pressed.

### Place Your Code Here ###

if (key == 'r'):

fishBody.centerX = 340

fishBody.rotateAngle = 0

fishBody.centerY = 340

fishTail.rotateAngle = 0

fishTail.centerX = 365

fishTail.top = 330

pass

def onMouseDrag(mouseX, mouseY):

# If fish is very close to boat, pull it up.

### (HINT: Use a helper function.)

### Place Your Code Here ###

if (fishBody.left < 140):

pullUpFish()

# If the mouse is behind the fish, only move the line.

### Place Your Code Here ###

elif (mouseX > 340):

fishingLine.x2 = mouseX

fishingLine.y2 = mouseY

# If the mouse is too far from the fish, only move the line.

### (HINT: They are too far when horizontal distance between them is more

# than 80.)

### Place Your Code Here ###

elif (mouseX < 260):

fishingLine.x2 = mouseX

fishingLine.y2 = mouseY

# If the mouse is close enough to the fish and below the water, the line

# should hook the fish.

### (HINT: If the line 'hooks' the fish, both the line and the fish

# should move.)

### Place Your Code Here ###

elif (mouseY > 300):

fishingLine.x2 = mouseX

fishingLine.y2 = mouseY

fishBody.centerX = mouseX+ 25

fishTail.centerX = mouseX+ 50

fishBody.centerY = mouseY

fishTail.centerY = mouseY

this is what I've got so far,

https://academy.cs.cmu.edu/sharing/chartreuseBee9760

I cant seem to get the fish past where I put the restrictions any fixes?

Communication competence is defined as “the ability to effectively and appropriately interact in any given situation.” How can you demonstrate you are a competent communicator in the virtual classroom or the workplace?

Answers

One must show that one can communicate in a clear, considerate, and professional manner in order to pass the review.

What is communication competence?

The capacity to accomplish communication goals in a socially acceptable way is known as communicative competence. It comprises the capability to choose and apply abilities that are appropriate and effective in the relevant situation. It is organized and goal-oriented.

Presentation, active listening, nonverbal communication, and offering and receiving feedback, among other things, are some of the most crucial communication skills for any work.

Therefore, one must show that one can communicate in a clear, considerate, and professional manner in order to pass the review.

To learn more about communication competence, refer to the link:

https://brainly.com/question/29797967

#SPJ1



11. Which one of the following buttons is used for paragraph alignment?

11. Which one of the following buttons is used for paragraph alignment?

Answers

Answer:

C

Explanation:

Option A is used for line spacing.

Option B is used for right indent.

Option C is used for right paragraph alignment.

Option D is used for bullet points.

The button used for paragraph alignment would be option C.

Other Questions
Describe the obama administration's national northern border counternarcotics strategy recursive function that accepts a stack of integers as a parameter and replaces every even value in the stack with two occurrences of that value escriba descripcion objetiva y subjetiva de su familia 5.00 grams of calcium metal was reacted with 100.0 mL of a 2.500 M HCl solution in a coffee cup calorimeter. The temperature went from 20.5oC to 35.5oC. Determine the reaction enthalpy per mole of calcium. The specific heat of the solution is 4.180 J/goC. Assume a solution density of 1.03g/mL.Please provide them step-by-step. Heat of reaction equation = (mass)(specific heat)(change of temp.) Which statement best explains a pattern in the evidence of life found in the fossilrecord?A. Fossils of living things found in younger rocks are the commonancestors of those whose fossils are found in older rock.B. Fossils in the oldest layers of rock show that the first living things weremore complex than younger forms.C. Life on Earth has always included small single-celled forms and largemulticelled formsD. Life on Earth changed from consisting of only small, single-celledorganisms to including large, multicellular organisms. the suffix-able helps the reader determine that the word reliable is - A. An adjective or descriptive word B. A verb or action C. A proper noun D. A word from a language other than English * Suppose product XYZ has 14 different features that are ranked 1 through 14. With ' ' interpreted as, 'strictly preferred to', suppose the ranking satisfies, 1234567891011121314. Suppose Firm A offers a version of the product that has Features 1 through 7, and Firm B a version of the product that has Features 8 through 14. Denote Firm A's price, p(A,XYZ) and Firm B's price, p(B,XYZ) (a) What is the relation between p(A,XYZ) and p(B,XYZ) ? Suppose Firm A attempts to upgrade its version of product XYZ. Suppose the upgrade improves Features 5 through 7 only. Suppose Firm B also attempts to upgrade its version of product XYZ. Suppose the upgrade improves Features 8 through 10. Denote the new prices that Firms A or B ought to charge by, q(A,XYZ) and q(B,XYZ). (b) Using inequalities, what are the relations between p(A,XYZ), p(B,XYZ),q(A,XYZ), and q(B,XYZ) ? Suppose Firm A attempts to upgrade its version of product XYZ. Suppose the upgrade improves Features 5 through 7 only. Suppose Firm B also attempts to upgrade its version of product XYZ. Suppose the upgrade improves Features 12 through 14. Denote the new prices that Firms A or B ought to charge by, r(A,XYZ) and r(B,XYZ). (c) Using inequalities, what are the relations between p(A,XYZ), p(B,XYZ),r(A,XYZ), and r(B,XYZ) ? ......(we/tell) what's in next week's test? the first n terms of the progression. The first term and common difference of an arithmetic progression are a and -2. respectively. The sum of the first n terms is equal to the sum of the first 3n terms Express a in terms of n. Hence, show that n = 7 if a = 27. You decide to create a new type of energy bar. You take some samples to a focus group to get their reactions to your product. Which stage of the development process are you in?A. Idea GenerationB. Maker Strategy CreationC. Concept DevelopmentD. Product Development Information from the Human Genome Project will:A.all of the them.B.help to reveal the role and implications of evolutionC.be useful for diagnosing and treating genetic diseases.D.reveal the location of a gene on a particular chromosome. Please answer thisAnswer choiceA. Subtraction Property Of EqualityB.Associative Property Of EqualityC.Division Property Of EqualityD.Addition Property Of Equality Ka for boric acid is 7.3 x 1010. What is the pKa of boric acid?A4.86B9.14C8.66D-4.86 What was Paul Robeson known for? a. Fill in the survival rate, the survivorship schedule (lx), the lxFxcolumn, and calculate R0, the net reproductive rate.(b) Interpret the answer for question 1: Based on the R0, is the average individual replacing herself or not? Do you expect this population is growing, shrinking, or stable?(c) Make a graph of the survivorship curve and paste it below, or sketch a graph in Word or by hand. Which type of survivorship curve (I, II, or III) does this population have? What does this survivorship curve tell us about patterns of mortality in the population? (Remember that the y-axis on a survivorship graph is plotted on a log scale. if You can guess my favorite anime I'll give you brainliest :DD What is Lotus of Siam known for? Top Care is a company that offers residential health care services. The company has $150 million in interest-bearing debt (in book value and market value terms). The firm has 30 million shares trading at $10 a share, and the unlevered beta of firms in the health care business is 1.1. The firm has a current rating of B, with a default spread of 0.05 over the risk free rate. The risk free rate is 0.045, the equity risk premium is 0.07 and the corporate tax rate is 40%.Top Care is considering making a new investment of $ 1000000 and has come with the following estimated revenues are$5000000 , operating expenses $550000, depreciation $250000 per year. The project will end after four years. This project will require Top care to maintain working capital at 20% of revenues occurring at the beginning of each year and the working capital being recovered at the end.Estimate the debt to capital ratio for the firm.Answer for part 1Estimate the debt to equity ratio for the firm.Answer for part 2What is the beta levered for the firm?Answer for part 3Estimate the before tax cost of debt for the firm.Answer for part 4Estimate the after tax cost of debt for the firm.Answer for part 5Estimate the cost of equity for the firm.Answer for part 6Estimate the weighted average cost of capital for the firm.Answer for part 7Estimate the annual EBIT to the firm to Top Care on this investment. (You have to do it only once, since the revenues and expenses flows are the same every year)Answer for part 8Estimate the FCFF on the project for year 1.Hint: FCFF= EBIT(1-t) + depreciation - capex +or- change in net working capitalAnswer for part 9Estimate the FCFF on the project for year 2.Answer for part 10Estimate the FCFF on the project for year 3.Answer for part 11Estimate the FCFF on the project for year 4.Answer for part 12Estimate the initial investment.Answer for part 13Estimate the NPV of the project.Answer for part 14 Which of the following uses logical order for the arrangement of ideas?A narrative essayO A descriptive essayOAn argumentative essayO A memoir A sauce should do all of the following except __________.