Questions 4 -7 are fill-in answers based on chapter 6
Dictionaries and the examples reviewed in class:
Provide just the answers as comments; not the questions. The answer
should demonstrate your knowledge of Python vocabulary and
syntax.
4) What is the name of the programming language we are studying?
__________________________________
5) student = {‘name’ : ‘Phil’, ‘age’ : 20} student[‘age’] =
21
student[‘gpa’] = 3.5
After execution of the above 3 statements, how many items are in the dictionary?
___________________
6) student = {'name': 'John', 'major': 'CSIS', 'age': 20,'id': 40}
if 'name' not in student.keys():
print('this is confusing');
Will the if statement evaluate to true or false?
________________________________
7) Name three simple Python data types and name 2 complex Python data types.
4) the name of the programming language we are studying is Python Answer: Python 5) student = {‘name’ : ‘Phil’, ‘age’ : 20} student[‘age’] = 21 student[‘gpa’] = 3.5 After execution of the above 3 statements, Number of items are in the dictionary is 3 Answer: 3 6) student = {'name': 'John', 'major': 'CSIS', 'age': 20,'id': 40} if 'name' not in student.keys(): print('this is confusing'); if statement evaluate to false Answer: false 7) three simple Python data types are int,float,str 2 complex Python data types are list, dict
Questions 4 -7 are fill-in answers based on chapter 6 Dictionaries and the examples reviewed in...
Questions 1. How to create a comment in python? 2. The way to obtain user input from command line 3. List standard mathematical operators in python and explain them 4. List comparison operators in python 5. Explain while loop. Give example 6. Explain for loop. Give example 7. How to create infinite loop? And how to stop it? 8. Explain a built-in function ‘range’ for ‘for’ loop 9. Explain break statement 10. Explain continue statement 11. Explain pass statement 12....
Using the answers from the table above, answer ALL of the questions below. For questions 1 - 13, draw a normal curve and indicate the area that you are calculating the probability of. For questions 14 – 22, use the appropriate formulas and show all of your calculations. Be sure to turn in the table above along with your answers to all of the questions below. Place your answers in a folder with your name clearly written at the top...
Circle or fill in the correct response. Unless otherwise noted, all answers will be worth 6 points: 1. A mushroom head push button on an emergency stop circuit typically uses N.O / N.C contacts 2. Multiple start buttons are connected in series/parallel in a motor control circuit 3. Multiple stop buttons are connected in series/ parallel in a motor control circuit 4. If a hardwired circuit required a second load to energize a set amount of time after turning the...
ctivity-Based Costing, Activity Identification, Activity Dictionary Golding Bank is in the process of implementing an activity-based costing system. A copy of an interview with the manager of Golding's Credit Card Department follows. QUESTION 1: How many employees are in your department? RESPONSE: There are eight employees, including me. QUESTION 2: What do they do (please describe)? RESPONSE: There are four major activities: supervising employees, processing credit card transactions, issuing customer statements, and answering customer questions. QUESTION 3: Do customers outside...
Please do not delete the questions. 1. What is the purpose of a database? 2. What is the reason to use a database over a spreadsheet? 3. Based on the previous answers (#1 & #2), there is a simple rule of thumb. A spread sheet is used when there is _________________________. A database is used when there are _________________________. 4. Please answer followings. a) A group of 8 bits is called a ____________ (from Chapter 4). b) The answers of...
Select the BEST answer for each of the questions below (I true, F- false). Cirele the letter that corresponds with the answer you have selected. Each question is worth 2 points. [Total 40 points) Answer uestion E1. Power is the ability to reject the null hypothesis when it should be rejected 2. With curvilinear data, the Pearson r statistic is an appropriate, accurate statistical tool In a research report, the term statistically significant is used to indicate that the null...
Question 1 An array is NOT: A - Made up of different data types. B - Subscripted by integers. C - A consecutive group of memory chunks. D - None of the choices. Question 2 How many times is the body of the loop executed? int i=1; while(true) { cout << i; if(++i==5) break; } A - Forever B - 4 C - 5 D - 6 E - 0 Question 3 What is wrong with the following piece of...
i have the case study question with the answers but i need help to re-write the answers. please see the attached files Case Study Analysis (CSF3003) Assessment Description and Requirements CLO1: Case Study 1 Ahmad lef home to study master and PhD in Australia. He has fees for the first semester only. After he arrived to Sydney and settled down, he start looking for a part-time job to save money for the next term. Ahmad has some experience on making...
If you’re using Visual Studio Community 2015, as requested, the instructions below should be exact but minor discrepancies may require you to adjust. If you are attempting this assignment using another version of Visual Studio, you can expect differences in the look, feel, and/or step-by-step instructions below and you’ll have to determine the equivalent actions or operations for your version on your own. INTRODUCTION: In this assignment, you will develop some of the logic for, and then work with, the...