1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
quester [9]
3 years ago
15

zyDE 8.14.1: Iterating over a dictionary example: Gradebook statistics. Write a program that uses the keys(), values(), and/or i

tems() dict methods to find statistics about the student_grades dictionary. Find the following: Print the name and grade percentage of the student with the highest total of points. Find the average score of each assignment. Find and apply a curve to each student's total score, such that the best student has 100% of the total points.
Business
1 answer:
galben [10]3 years ago
7 0

Answer:

Explanation:

# keys() will be assignmentects1, assignmentect2 etc

# values() will be the marks in each assignmentect like 56, 79 etc

AndrewMarks = { 'assignment1': 56,

'assignment2': 79,

'assignment3': 90,

'assignment4': 22,

'assignment5': 50 }

ColinMarks = { 'assignment1': 88,

'assignment2': 62,

'assignment3': 68,

'assignment4': 75,

'assignment5': 78 }

AlanMarks = { 'assignment1': 95,

'assignment2': 88,

'assignment3': 92,

'assignment4': 85,

'assignment5': 85 }

MaryMarks = { 'assignment1': 76,

'assignment2': 88,

'assignment3': 85,

'assignment4': 82,

'assignment5': 90 }

TriciaMarks = { 'assignment1': 99,

'assignment2': 92,

'assignment3': 95,

'assignment4': 89,

'assignment5': 99 }

# Calculate total of each student and store them in the new dictionary

AndrewTot = AndrewMarks['assignment1'] + AndrewMarks['assignment2'] + AndrewMarks['assignment3'] + AndrewMarks['assignment4'] + AndrewMarks['assignment5']

ColinTot = ColinMarks['assignment1'] + ColinMarks['assignment2'] + ColinMarks['assignment3'] + ColinMarks['assignment4'] + ColinMarks['assignment5']

AlanTot = AlanMarks['assignment1'] + AlanMarks['assignment2'] + AlanMarks['assignment3'] + AlanMarks['assignment4'] + AlanMarks['assignment5']

MaryTot = MaryMarks['assignment1'] + MaryMarks['assignment2'] + MaryMarks['assignment3'] + MaryMarks['assignment4'] + MaryMarks['assignment5']

TriciaTot = TriciaMarks['assignment1'] + TriciaMarks['assignment2'] + TriciaMarks['assignment3'] + TriciaMarks['assignment4'] + TriciaMarks['assignment5']

TotalMarks = { 'Andrew': AndrewTot,

'Colin' : ColinTot,

'Alan' : AlanTot,

'Mary' : MaryTot,

'Tricia': TriciaTot}

StudentHighestTotal = max(TotalMarks)

HighestTotalMarks = TotalMarks[max(TotalMarks)]

Averages = { 'assignment1Average': (AndrewMarks['assignment1'] + ColinMarks['assignment1'] + AlanMarks['assignment1'] + MaryMarks['assignment1'] + TriciaMarks['assignment1'] ) / 5 ,

'assignment2Average': (AndrewMarks['assignment2'] + ColinMarks['assignment2'] + AlanMarks['assignment2'] + MaryMarks['assignment2'] + TriciaMarks['assignment2'] ) / 5 ,

'assignment3Average': (AndrewMarks['assignment3'] + ColinMarks['assignment3'] + AlanMarks['assignment3'] + MaryMarks['assignment3'] + TriciaMarks['assignment3'] ) / 5 ,

'assignment4Average': (AndrewMarks['assignment4'] + ColinMarks['assignment4'] + AlanMarks['assignment4'] + MaryMarks['assignment4'] + TriciaMarks['assignment4'] ) / 5 ,

'assignment5Average': (AndrewMarks['assignment5'] + ColinMarks['assignment5'] + AlanMarks['assignment5'] + MaryMarks['assignment4'] + TriciaMarks['assignment5'] ) / 5

}

You might be interested in
Explain how each of the following events changes the demand for or supply of jeans. A. Upper A new technology becomes available
Dima020 [189]

Answer:

A. Where a new technology that reduces the time it takes to manufacture a pair of jeans is available, it will leads to a change in supply. For example if a new machine is invented which decreases output per unit of time, there will decrease in the supply of a pair of jeans.

B. Where the price of the cloth (denim) used to make jeans rises, it will affect the change in the supply of jeans because an increase in the price of the raw materials used (denim) in making jeans, it will lead to a reduction in supply.

C. Where Jeans go out of fashion, it will cause a change in demand or supply because taste changes over time. For example, if jeans go out of fashion there would be a decrease in demand and supply for it.

D. Where the price of a pair of jeans falls, it will not affect the change in demand or supply of the jeans because a change in the price of a commodity is not a factor that causes a change in demand or supply.

E. Where the wage rate paid to garment workers falls, it will affect the change in the supply of jeans but will not affect the change in demand for jeans.

F. Where many jeans producers go out of business, it will affect the change in the supply of jeans but will not affect the change in demand for jeans.

H. Where people's incomes increase, it will affect the change in demand that leads to increase in demand for a pair of jeans

Explanation:

Causes of changes in demand and supply

Demand refers to the quantity of a commodity which consumers are willing and able to purchase at a particular price and at a particular period of time.

The Law of demand sates that 1) the higher the price of a commodity, the lower the quantity demanded, and  2) the lower the price of a commodity, the higher the quantity demanded.

The Change in demand (shift in the demand curve): There is a change in demand if the demand curve shifts to an entirely new position. A change in demand is determined by the factors affecting demand, other than price in a commodity. Factors affecting change in demand include changes in taste, fashion, population size, and income. 

The Supply of a commodity is the quantity of that commodity which sellers are willing and able to offer for sale at a particular price, at a particular period of time.

The Law of supply states that the higher the price of a commodity, the higher the quantity supplied while the lower the price of a commodity, the lower the quantity supplied.

The Change in supply (shift in the supply curve): There is a change in supply if the supply curve shifts to an entirely new position. A change in supply is determined by the factors affecting supply, other than price in a commodity. Factors affecting supply include Technological development, weather and climate, government policies/effects of subsidies and taxation, a new source of raw materials. A change in supply could be a decrease or increase in supply of a commodity. 

8 0
3 years ago
Suppose that the equation for the SML is Y = 0.05 + 0.07X, where Y is the average expected rate of return, 0.05 is the vertical
timurjin [86]

Answer:

Risk free interest rate is 5%

Y is 15.5% at a Beta of 1.5

X is 0.29 when Y is 7%

Explanation:

Risk free interest is 0.05 which 5% as given in the equation

The average expected return is given by Y

Y=0.05+0.07X

Since Beta is the same as X, when equals 1.5,Y is calculated thus

Y=0.05+0.07(1.5)

Y=0.05+0.105

Y=0.155

Y=15.5%

The value of Beta at an average return of 7% is computed thus:

7%=0.05+0.07X

where X is the unknown

0.07=0.05+0.07X

0.07-0.05=0.07X

0.02=0.07X

X=0.02/0.07

X=0.29

The scenario  illustrates that the Beta, which is the risk of investment and the Y , the expected average return are positively correlated.

6 0
3 years ago
(Ignore income taxes in this problem.) If you wanted to withdraw $12,000 from a bank account at the end of each of the next 20 y
prisoha [69]

Answer:

The money should be invested in bank = $137,639.05

Explanation:

Given  annually withdrawal money (annuity ) = $12000

Number of years (n ) = 20 years

Interest rate  = 6 percent.

Since a person withdraw money annually for next 20 years with 6 percent interest rate. Now we have to calculate the amount that have been invested in the account today. So below is the calculation for invested money.  

\text{Present value of annuity} = \frac{Annuity [1-(1 + r)^{-n}]}{rate} \\= \frac{12000 [1-(1 + 0.06)^{-20}]}{0.06} \\=12000 \times 11.46992122 \\=137,639.05

4 0
3 years ago
Ozone (O3) is a gas in the earth's atmosphere. How do you know that ozone is covalently bonded and not ionically bonded?
garik1379 [7]

Answer:

The answer is below

Explanation:

A covalent bond is a type of chemical bond that occurs as a result of the sharing of electron pairs between atoms. Covalent bonds are usually formed between non metallic atoms with similar electronegativity. St room temperature, covalent bond exist as either a liquid or a gas. Example of covalent bonds are ozone (O3), water (H2O) etc.

Ozone is said to be covalent bonded because their is a sharing of electrons among the covalent atoms.

5 0
2 years ago
Money taken out of a salary for such things as taxes, medical insurance, and retirement funds is called
Andre45 [30]
A. deductions as these are the items that are deducted from your salary. 
5 0
3 years ago
Read 2 more answers
Other questions:
  • At an output level of 15,200 units, you have calculated that the degree of operating leverage is 2.60. The operating cash flow i
    14·1 answer
  • It is unethical to report the wrongdoing of a coworker.
    15·2 answers
  • If you are a buyer with a buyer value of $6.50, would you be willing to buy a book for $6.25?
    6·1 answer
  • What activity is designed to generate a listing of potential clients?
    7·1 answer
  • 3. In its most recent financial statements, Newhouse Inc. reported $50 million of net income and $810 million of retained earnin
    9·1 answer
  • Sea Side Enterprises is trying to predict the cost associated with producing its anchors. At a production level of 5 comma 500 ​
    12·1 answer
  • Marle Construction enters into a contract with a customer to build a warehouse for $950,000 on March 30, 2021, with a performanc
    7·1 answer
  • Pina Colada Corp. issued 22000 shares of $1 par common stock for $40 per share during 2022. The company paid dividends of $53000
    5·1 answer
  • joe, a hair dresser, offers students a discount price on haircuts. this form of pricing is an example of
    10·1 answer
  • Costs that are shared by multiple cost objects in a company are known as ______ costs.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!