Solved by verified expert:question is uploaded
csci_127__in_lab_9.pdf
practicum2_.pdf
Unformatted Attachment Preview
10/31/2017
CSCI 127, In-Lab 9
Lab 9: Review
Logistics
Due: Tuesday, October 31st no later than midnight.
Partner Information: Complete this assignment individually.
Submission Instructions: Upload your solution, named YourFirstName-YourLastName.py to the
BrightSpace Lab 9 Dropbox.
Deadline Reminder: Once this deadline passes, BrightSpace will no longer accept your Python submission
and you will no longer be able to earn credit. Thus, if you are not able to fully complete the assignment,
submit whatever you have before the deadline so that partial credit can be earned.
Learning Outcomes
This lab should help you prepare for Friday’s practicum by identify topics you understand well and topics
you need to continue practicing.
Assignment
Last Spring, a pilot offering of The Joy and Beauty of Data was offered at Bozeman High School. Answer
each question on the practicum that was given at BHS.
Grading – 10 points
3 points – Question 1 has an answer.
4 points – Question 2 has an answer.
3 points – Question 3 has an answer.
Grading note: You will receive full credit for submitting any reasonable answer. Sample solutions to each
question will be covered in lecture on November 1st.
If Time Remains
Work on Program 4, which is also due tonight at midnight, seeking feedback from your lab assistant if
desired.
https://www.cs.montana.edu/paxton/classes/csci127/inlabs/lab9/
1/1
Joy and Beauty of Data, Second Practicum – March 30, 2017
Name _______________________________________________________________
Question One. 25 points. Supply the missing function so that when this code runs:
stranger_things = {}
stranger_things[“The Vanishing of Will Byers”] = “The Duffer Brothers”
stranger_things[“The Weirdo on Maple Street”] = “The Duffer Brothers”
stranger_things[“Holly, Jolly”] = “Shawn Levy”
stranger_things[“The Body”] = “Shawn Levy”
stranger_things[“The Flea and the Acrobat”] = “The Duffer Brothers”
stranger_things[“The Monster”] = “The Duffer Brothers”
stranger_things[“The Bathtub”] = “The Duffer Brothers”
stranger_things[“The Upside Down”] = “The Duffer Brothers”
episodes_directed(stranger_things, “The Duffer Brothers”)
episodes_directed(stranger_things, “Shawn Levy”)
episodes_directed(stranger_things, “Kerri Cobb“)
The following output is produced:
The Duffer Brothers directed 6 episodes
Shawn Levy directed 2 episodes
Kerri Cobb directed 0 episodes
Question Two. 50 points. Supply the missing class and methods so that when this code runs:
# “Stranger Things” is the title of the series.
# “The Duffer Brothers” is the creator of the series.
# 1 is the number of seasons that the series has run.
# 8 is the number of episodes that the series contains.
stranger_things = Series(“Stranger Things”, “The Duffer Brothers”, 1, 8)
print(stranger_things)
stranger_things.addSeason()
stranger_things.addEpisodes(9)
print(stranger_things)
# here comes the next season
# there are now 9 more episodes
The following output is produced:
Stranger Things has aired 8 episodes over 1 seasons.
Stranger Things has aired 17 episodes over 2 seasons.
Question Three. 25 points. Object Oriented Concepts.
(a) What is the name of the constructor method in a class?
(b) Suppose the class Athlete is already defined and we want to define a new class called
Runner that is a subclass of Athlete. Complete the following one line of Python:
class Runner
(c) In the context of the Athlete class, give a concrete example of the difference between
an instance and an instance variable.
(d) Describe briefly the difference between a reader method and a writer method.
(e) To override the + operator, an __add__ method can be defined in a class. What method
must be defined to override the ** operator?
…
Purchase answer to see full
attachment
You will get a plagiarism-free paper and you can get an originality report upon request.
All the personal information is confidential and we have 100% safe payment methods. We also guarantee good grades
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.
Read moreEach paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.
Read moreThanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.
Read moreYour email is safe, as we store it according to international data protection rules. Your bank details are secure, as we use only reliable payment systems.
Read moreBy sending us your money, you buy the service we provide. Check out our terms and conditions if you prefer business talks to be laid out in official language.
Read more