Quiz 3 will take place on Thursday and Friday, 6/25 and 6/26, via D2L. You can take the quiz any time between 12am on Thursday, 6/25 and 11:59 pm Mountain Time on Friday, 6/26. You will have one hour to complete the short answer and multiple choice portion of the quiz once you start it. You can turn in the coding question as a .py file to the D2L dropbox until 11:59pm Mountain Time on 6/26. The quiz will cover the Python topics and data science topics that we have learned so far: data types, turtle graphics, modules, functions, selection statements, iterative statements, strings, recursion and lists, files, dictionaries, object oriented programming, Numpy, Matploblib, and Pandas, with a focus on material that we have learned since the last quiz (Numpy, Matploblib, and Pandas). If you have been able to complete the lab and programming assignments, you should be able to complete the quiz.
The quiz will consist of two parts. Part 1 will consist of five multiple choice or short answer questions that are similar to the questions found in the textbook. Part 2 will consist of one programming question. Unlike on previous quizes, you may not have seen this question before.
You may use a computer to develop your answers. You may only use the internet to access the interactive Python textbook, the course website (including videos), the Pythontutor code visualizer, the online Python documentation or previous Python programs that you wrote for this course (Labs 1-11 and Programs 1-5). You are encourage to use the IDLE shell and run Python source code.
Once you have viewed the quiz, you may NOT discuss it with anyone until Saturday, June 27th. Even telling a classmate that the quiz was difficult or easy is not acceptable.
Now on D2L!
Practice quiz answers:
forwardis a Turtle method,
=is the assignment operator,
Turtle()is the Turtle constructor, and
alexis a Turtle object.
- While loops, for loops, and recursion all let you repeat execution of the same code multiple times.
data.head()is a Pandas data frame.
arr = np.arange(9)
Practice quiz coding question
Quiz coding question
Download the billionaires dataset from this website. Download quiz3.py. Add the missing code so that this plot is produced. Hint: you can add a legend to your plot by including labels and calling
plt.plot(some_data, label="Label for this data") plt.legend()
See the matplotlib documentation here.