hw02.pdf - hw02 February 6 2019 1 Homework 2 Arrays and Tables In[2 Don't change this cell just run it import numpy as np from datascience import from

hw02.pdf - hw02 February 6 2019 1 Homework 2 Arrays and...

This preview shows page 1 - 3 out of 23 pages.

hw02 February 6, 2019 1 Homework 2: Arrays and Tables In [2]: # Don ' t change this cell; just run it. import numpy as np from datascience import * from client.api.notebook import Notebook ok = Notebook( ' hw02.ok ' ) ===================================================================== Assignment: Homework 2: Arrays and Tables OK, version v1.12.5 ===================================================================== Recommended Reading : * Data Types * Sequences * Tables Please complete this notebook by filling in the cells provided. Before you begin, execute the following cell to load the provided tests. Each time you start your server, you will need to execute this cell again to load the tests. Homework 2 is due Thursday, 2/7 at 11:59pm. Start early so that you can come to office hours if you’re stuck. Check the website for the office hours schedule. You will receive an early submission bonus point if you turn in your final submission by Wednesday, 2/6 at 11:59pm. Late work will not be accepted as per the policies of this course. Throughout this homework and all future ones, please be sure to not re-assign variables throughout the notebook! For example, if you use max_temperature in your answer to one ques- tion, do not reassign it later on. Important : In this homework, the ok tests will tell you whether your answer is correct, ex- cept for Parts 4, 5 & 6. In future homework assignments, correctness tests will typically not be provided. Before continuing the assignment, select "Save and Checkpoint" in the File menu and then execute the submit cell below. The result will contain a link that you can use to check that your assignment has been submitted successfully. If you submit more than once before the deadline, we will only grade your final submission. If you mistakenly submit the wrong one, you can head to okpy.org and flag the correct version. There will be another submit cell at the end of the assignment when you finish! In [3]: _ = ok . submit() 1
Image of page 1
<IPython.core.display.Javascript object> <IPython.core.display.Javascript object> Saving notebook... Saved ' hw02.ipynb ' . Performing authentication Please enter your bCourses email. bCourses email: [email protected] Copy the following URL and open it in a web browser. To copy, highlight the URL, right-click, and select "Copy". After logging in, copy the code from the web page, paste it below, and press Enter. To paste, right-click and select "Paste". Paste your code here: sqvklmoo4fYdwQGHX2YT02fWjz9teA Successfully logged in as [email protected] Submit... 100% complete Submission successful for user: [email protected] URL: 1.1 1. Creating Arrays Question 1. Make an array called weird_numbers containing the following numbers (in the given order): 1. -2 2. the sine of 1.2 3. 3 4. 5 to the power of the cosine of 1.2 Hint: sin and cos are functions in the math module. In [4]: # Our solution involved one extra line of code before creating # weird_numbers.
Image of page 2
Image of page 3

You've reached the end of your free preview.

Want to read all 23 pages?

  • Fall '17
  • World population

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Stuck? We have tutors online 24/7 who can help you get unstuck.
A+ icon
Ask Expert Tutors You can ask You can ask You can ask (will expire )
Answers in as fast as 15 minutes
A+ icon
Ask Expert Tutors