$20 Bonus + 25% OFF
$20 Bonus + 25% OFF
Securing Higher Grades Costing Your Pocket? Book Your Assignment at The Lowest Price Now!
Add File

Error goes here

CS50 Python Programming

tag 18 Downloads3 Pages / 586 Words tag Add in library Click this icon and make it bookmark in your library to refer it later. GOT IT


You are to present your findings in the form of a problem based report. This report should describe how you approached the solution to the problem (program design), how you implemented the program (source code and screen shots) and the approach you used to test that the program works (you should include a print out of your test results as part of the report). You will also evaluate how effective your solution is, and where you feel any improvements could be made.
Assignment Task
1. Create a list called years_list, starting with the year of your birth, and each year
thereafter until the year of your fifth birthday. For example, if you were born in 1980 the list would be years_list = [1980, 1981, 1982, 1983, 1984, 1985].
2. In which year in years_list was your third birthday? Remember, you were 0 years of age for your first year.
3. In which year in years_list were you the oldest?
4. Make a list called things with these three strings as elements: "mozzarella", "cinderella", "salmonella".
5. Capitalize the element in things that refers to a person and then print the list. Did it change the element in the list?
6. Make the cheesy element of things all uppercase and then print the list.
7. Delete the disease element from things, collect your Nobel Prize, and print the list.
8. Create a list called surprise with the elements "Groucho", "Chico", and "Harpo".
9. Lowercase the last element of the surprise list, reverse it, and then capitalize it.
10. Make an English-to-French dictionary called e2f and print it. Here are your starter words: dog is chien, cat is chat, and walrus is morse.
11. Using your three-word dictionary e2f, print the French word for walrus.
12. Make a French-to-English dictionary called f2e from e2f. Use the items method.
13. Using f2e, print the English equivalent of the French word chien.
14. Make and print a set of English words from the keys in e2f.

15. Make a multilevel dictionary called life. Use these strings for the topmost keys: 'animals', 'plants', and 'other'. Make the 'animals' key refer to another dictionary with the keys 'cats', 'octopi', and 'emus'. Make the 'cats' key refer to a list of strings with the values 'Henri', 'Grumpy', and 'Lucy'. Make all the other keys refer to empty dictionaries.
16. Print the top-level keys of life.
17. Print the keys for life['animals'].
18. Print the values for life['animals']['cats'].
19 Assign the value 7 to the variable guess_me. Then, write the conditional tests (if,else, and elif) to print the string 'too low' if guess_me is less than 7, 'too high' if greater than 7, and 'just right' if equal to 7.
20. Assign the value 7 to the variable guess_me and the value 1 to the variable start.
Write a while loop that compares start with guess_me. Print too low if start is less
than guess me. If start equals guess_me, print 'found it!' and exit the loop. If start
is greater than guess_me, print 'oops' and exit the loop. Increment start at the end of the loop.
21. Use a for loop to print the values of the list [3, 2, 1, 0].
Download Sample Now

Earn back the money you have spent on the downloaded sample by uploading a unique assignment/study material/research material you have. After we assess the authenticity of the uploaded content, you will get 100% money back in your wallet within 7 days.

Unique Document

Under Evaluation

Get Money
into Your Wallet

Total 3 pages, 1 USD Per Page

Cite This Work

To export a reference to this article please select a referencing stye below:

My Assignment Help. (2021). Python Programming. Retrieved from https://myassignmenthelp.com/free-samples/cs50-python-programming/conditional-statements.html.

My Assignment Help (2021) Python Programming [Online]. Available from: https://myassignmenthelp.com/free-samples/cs50-python-programming/conditional-statements.html
[Accessed 26 September 2021].

My Assignment Help. 'Python Programming' (My Assignment Help, 2021) <https://myassignmenthelp.com/free-samples/cs50-python-programming/conditional-statements.html> accessed 26 September 2021.

My Assignment Help. Python Programming [Internet]. My Assignment Help. 2021 [cited 26 September 2021]. Available from: https://myassignmenthelp.com/free-samples/cs50-python-programming/conditional-statements.html.

For years now, MyAssignmenthelp.com is providing affordable essay help to millions of students worldwide. Our essay assistance services have helped us in assisting students with even the toughest essay assignments. We take pride in the fact that we cater the best assistance to search terms like help me with my essay. We offer affordable services in the fastest way possible. For our fast delivering services, students trust us with their urgent essay assignment needs. Two of our most popular essay writing services are maths essay help and English essay help.

Latest Programing Samples

BN102 Web System

Download : 0 | Pages : 7

Answer Introduction Bad website design is usually characterized by many factor that do not make website appealing and easy to use. In this case, a discussion of Smith and Goldsmith Inc. rental properties website will be evaluated. An analysis of a good website practices explain that, a good website should be easy to navigate by locating links, should not be too clumsy and should have attractive appearance. All these aspects cannot be traced fro...

Read More arrow

SITIS2 Information Systems And Data Science

Download : 0 | Pages : 7

Answers: Introduction:  A portal development is done by a real estate company. Their current system is analyzed and a report is needed to make in the back-end of that application system. An interview is conducted by the assessor for finding the class specifications utilized in the system. The following report reviews the classes and objects used in the system. 1. Analyzing the behavior of the objects in the application:  1.1. The...

Read More arrow Tags: Australia Concord Management analysing the strategic  tactical and operational levels of online store  The Book Depository University of New 

ITECH1000 Programming

Download : 0 | Pages : 5

Answer: Australia media debated and discussed recently a lot over affordability of own house for first home owners and for a month it was daily headlines of the newspaper, as some individual made a remark that new generation people spends a lot on takeaway coffees and avocado on toasts and if they stop buying it for some time they can save the money for the house deposit. This remark made a sensation amongst new generation’s people and t...

Read More arrow

BN104 Operating Systems

Download : 0 | Pages : 2

Answers: 1a. The comparison between the internal and external fragmentation: EXTERNAL  FRAGMENTATION INTERNAL FRAGMENTATION The fragmentations that are external occur due to the allocation of the processes in a variable sized memory. The fragmentations that are internal generally occur due to the allocation of the process in the fixed sized memory. The fragmentation that are external takes place whe...

Read More arrow

BN102D Web Systems

Download : 0 | Pages : 6

Answer: Introduction Two Websites are selected for review and they are listed as follows: Penny Juice (http://www.pennyjuice.com/htmlversion/whoispj.htm) Tinkering Monkey (http://www.tinkeringmonkey.com/) Penny Juice is considered as a bad website and tinkering Monkey is considered as an example of good website. The two criteria that is the Navigation and the visual effect is considered for reviewing the website. Identification of th...

Read More arrow Tags: Australia Camellia Computer Science Website Development University of New South Wales Engineering 

5% Cashback

On APP - grab it while it lasts!

Download app now

*Offer eligible for first 3 orders ordered through app!

callback request mobile
Have any Query?