Question

create three plots within a single graph, namely a plot, a scatter, and a bar superimposed...

create three plots within a single graph, namely a plot, a scatter, and a bar superimposed on over the other. x-axis indices beginning with 1 and y-axis are grades that were entered by using an infinite loop

in python

Homework Answers

Answer #1

A for loops allows us to execute a block of code multiple times with some parameters updated each time through the loop .A for loop begins with the for statement:

iterable=[1,2,3]

for item in iterable:

# code block indented 4 spaces

print(item)

1

2

3

The main points to observe are:

for and in keywords

iterable is a sequence object such as a list, tuple or range

item is a variable which takes each value in iterable

ends for statement with a colon:

code block indented 4 spaces which executes once for each value initerable

For example ,let's print n*2 for n from 0 to 5:

for n in [0,1,2,3,4,5]:

square=n**2

print(n,'squared is ',square)

print('The for loop is complete!)

0 squared is 0

1 squared is 1

2 squared is 4

3 squared is 9

4 squared is 16

5 squared is 25

The for loop is comlete!

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
A data set is given below. ​(a) Draw a scatter diagram. Comment on the type of...
A data set is given below. ​(a) Draw a scatter diagram. Comment on the type of relation that appears to exist between x and y. ​(b) Given that x over bar x = 3.5000 sx =2.58842. y =3.98333. sy=2.1085 and r = −0.9620​, determine the​ least-squares regression line. ​(c) Graph the​ least-squares regression line on the scatter diagram drawn in part​ (a). x 00 11 33 55 66 66 y 5.95.9 6.66.6 5.05.0 2.62.6 1.71.7 2.12.1 A. 0607xy A scatter...
What tools could AA leaders have used to increase their awareness of internal and external issues?...
What tools could AA leaders have used to increase their awareness of internal and external issues? ???ALASKA AIRLINES: NAVIGATING CHANGE In the autumn of 2007, Alaska Airlines executives adjourned at the end of a long and stressful day in the midst of a multi-day strategic planning session. Most headed outside to relax, unwind and enjoy a bonfire on the shore of Semiahmoo Spit, outside the meeting venue in Blaine, a seaport town in northwest Washington state. Meanwhile, several members of...
1. The failure of the new supply chain system affected Nike adversely. What were the reasons...
1. The failure of the new supply chain system affected Nike adversely. What were the reasons for the failure and how did the breakdown harm Nike? 2. What are the important elements to be kept in mind while implementing a new system in an organization? What is the importance of a good working relationship between partners and the sharing of responsibility in implementing critical projects? What mistakes did Nike and i2 make? 3. comment on the lessons learned and the...
Please answer the following Case analysis questions 1-How is New Balance performing compared to its primary...
Please answer the following Case analysis questions 1-How is New Balance performing compared to its primary rivals? How will the acquisition of Reebok by Adidas impact the structure of the athletic shoe industry? Is this likely to be favorable or unfavorable for New Balance? 2- What issues does New Balance management need to address? 3-What recommendations would you make to New Balance Management? What does New Balance need to do to continue to be successful? Should management continue to invest...