Spring Semester 09 Exam #1 Dr. Dillon. (02/19)
|
|
- Andrew Bell
- 5 years ago
- Views:
Transcription
1 Spring Semester 09 Exam #1 Dr. Dillon. (02/19) Form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 90 minutes to complete the exam (12:40 2:00 pm) c) This exam booklet contains 26 multiple choice questions, each weighted equally (5 points) and one 20 point programming problem. (27 questions, 10 total pages) d) There is an ASCII table on the last page of the exam for your reference. e) You may also use one 8.5" x 11" note sheet during the exam. No other reference materials or calculating devices may be used during the examination. f) Questions will not be interpreted during the examination. g) You should choose the single best alternative for each question, even if you believe that a question has multiple correct answers, is ambiguous or contains a typographic error. h) Fill in the requested information at the top of this exam booklet. i) Use a #2 pencil to encode information on the OMR form. j) Encode the following on the OMR form: Last name and first initial MSU PID Exam form (see the top right corner of this page) k) Sign the OMR form. l) Only answers recorded on your OMR form will be counted for credit for multiplechoice questions. m) Completely erase any responses on the OMR form that you wish to delete. n) You must turn in this exam booklet and the OMR form when you have completed the exam. When leaving, please be courteous to those still taking the exam. Good luck. Timing tip. A rate of 2.5 minutes per multiple choice problem leaves 15 minutes to write the program (worth 20 points) at the end :a, 02:c, 03:c, 04:d, 05:b, 06:a, 07:c, 08:d, 09:d, 10:d, 11:e, 12:a, 13:a, 14:b, 15:c, 16:b, 17:d, 18:a, 19:c, 20:b, 21:a, 22:a, 23:b, 24:a, 25:b, 26:a
2 Figure 1 1) In Figure 1, if the user enters 6 at the prompt, what is printed by Line E? a) s = 6.0 b) s = 12.0 c) s = 6 d) s = 12. 2) In Figure 1, if the user enters 6 at the prompt, what is printed by Line F? a) t = 0 b) t = 1 c) t = 2 d) t = 3. 3) In Figure 1, if the user enters 6 at the prompt, what is printed by Line G? a) num = 0 b) num = 0.0 c) num = 2 d) num = 2. 4) In Figure 1, what effect would removing Line A have, assuming the user enters 6? a) No affect the program would produce the same results as before. b) The while loop would not terminate. c) An error would occur when the condition (num > 0) is evaluated in Line B. d) An error would occur when the condition num%5 is evaluated in Line C.. 5) In Figure 1, what effect would removing Line D have, assuming the user enters 6? a) No affect the program would produce the same results as before. b) The while loop would not terminate. c) The program could not be run because of a syntax error. d) The program would print a larger value for num at Line G.
3 6) In Figure 1, type does the variable num have when Line D is executed? a) Integer (int) b) Boolean c) String (str) d) Its type depends on which suite of the if instruction, which begins at Line C, is executed.. 7) Which of the following has the effect of swapping (interchanging) the values of the variables a and b? a) a = b b) t, a, b = a, b, t c) a, b = b, a d) a.swap(b) 8) Which of the following statements is true? a) A modern day computer system often has more than one processor. b) An external hard drive is an example of secondary storage. c) Primary storage requires power to retain information. d) All of the above.. 9) Suppose you type the following into the Python shell at the >>>-prompt: range(12,100,10)[-1] What value does the shell return? a) A side-effect occurs, but no value is returned. b) 100 c) 99 d) 92.
4 Figure 2 10) In Figure 2, if the user types wo at the prompt what value is output by Line E? a) wooo b) wooooo c) woooowoooo d) wooooowooooo. 11) In Figure 2, if the user types hi at the prompt what value is output by Line E? a) hihihihi b) hihi c) hioohioo d) hioo 12) In Figure 2, if the user types 5a 3b at the prompt what value is output by Line E? a) 5a 3b5a 3b b) 5a5a5a c) 5aoooo d) 5aoooo5aoooo. 13) Which statement about the instruction in Line C of Figure 2 is true? a) It produces a side effect. b) It evaluates the expression ( oo ) on the right hand side of the equals sign (=) to obtain a value, and associates this value to the name mystr. c) It prints the value of the expression mystr + oo d) Depending on the type, any one of the above could be true. is true. 14) Which statement about the instruction in Line D of Figure 2 is true? a) Depending on the user input, it may be executed multiple times. b) Depending on the user input, it may never be executed. c) It is always executed exactly once, regardless of the user input. d) It is always executed multiple times, regardless of the user input..
5 Figure 3 15) Which of the following Python programs implement the control flow graph shown in Figure 3? a) while True: n = int(raw_input( Enter an int: )) if n== A1: continue elif n == A2: break print what print ever b) while True: n = int(raw_input( Enter an int: )) if n== A1: continue elif n == A2: break print what print ever c) while True: n = int(raw_input( Enter an int: )) if n== A1: continue elif n == A2: break print what print ever d) All of the (a) -- (c) e) None of (a) -- (c)
6 Figure 4 16) In Figure 4 what is printed by Line E? a) len(mylist) is 3 b) len(mylist) is 4 c) len(mylist) is 6 d) len(mylist) is 8 17) In Figure 4 what is printed by Line F? a) len(yrlist) is 3 b) len(yrlist) is 4 c) len(yrlist) is 6 d) len(yrlist) is 8 18) In Figure 4, what is printed by Line G? a) len(thlist) is 3 b) len(thlist) is 4 c) len(thlist) is 6 d) len(thlist) is 8 19) In Figure 4, what is printed by Line H? a) 1 b) 2 c) [1, 2] c) [2] 20) In Figure 4, what output is produced by execution of Line I? a) [1, 2] b) [1, 3] c) [2, 3] d) [2, 4] 21) Which of the following is true? a) In Python, a string value cannot be modified. b) In Python, the type of a variable is determined by its name. c) In Python, all data structures are mutable. d) All of the above..
7 22) What is printed by the following Python instruction if the value of val is 1: if val%2: print 0 print 1 a) 0 b) 1 c) Nothing the instruction contains a syntax error and cannot be executed. d) Nothing an error occurs when the instruction is executed. 23) What is printed by the following Python instruction if the value of val is 1: if 0 < val/3: print 0 print 1 a) 0 b) 1 c) Nothing the instruction contains a syntax error and cannot be executed. d) Nothing an error occurs when the instruction is executed. 24) What is printed by the following Python instruction if the value of val is 1: if 0 < (val/3.0) < val: print 0 print 1 a) 0 b) 1 c) Nothing the instruction contains a syntax error and cannot be executed. d) Nothing an error occurs when the instruction is executed. 25) What is printed by the following Python instruction if the value of val is 1: print (0!= val) or val a) 1 b) True c) (0!= val) or val d) Nothing an error occurs when the instruction is executed 26) What is printed by the following Python instruction if the value of val is 1: print val or (0!= val) a) 1 b) True c) val or (0!= val) d) Nothing an error occurs when the instruction is executed
8 27. Program question 20pts. Please, write on scrap paper first, then copy your answer to the next page. Make sure you put your name on the solution and hand it in at the end of the test. Background Every integer greater than 1 has a unique prime factorization into a product of one or more prime numbers in ascending order. For example: 12 = 2 * 2 * 3 39 = 3 * = 151 Requirements Your program must prompt for an integer greater than 1, and print out the integer together with its prime factorization. Hints You can find the prime factors of a number n by a very simple algorithm: Find the smallest integer n 1 larger than 1 that divides n and calculate the quotient q 1 of the n divided by n 1. If q 1 is greater than 1, then find the smallest integer n 2 larger than 1 that divides q 1 and calculate the quotient q 2 of q 1 divided by n 2. If q 2 is greater than 1, continue in this fashion to find n 3 and q 3. Keep going until you get a quotient of 1. The factors of n then consist of the divisors that you found: n 1, n 2, n 3, For example: Suppose the starting number is 126 o 2 is the smallest number larger than 1 that divides 126; the quotient is 63 o 3 is the smallest number larger than 1 that divides 63; the quotient is 21 o 3 is the smallest number larger than 1 that divides 21; the quotient is 7 o 7 is the smallest number larger than 1 that divides 7; the quotient is 1 Thus, the divisors are 2, 3, 3, 7. That is, 126 = 2 * 3 * 3 * 7 Start with a properly initialized list and add onto it until you have accumulated all the prime factors. Then print out the original number and the list of factors in ascending order. To save time, you do not have to worry about formatting the output as above. For example, for 126, you can simply output the message: The list of prime factors of 126 is: [2,3,3,7] Your program does not need to do any error checking. If the user gives it erroneous input, it can crash. Your program does not need to be efficient or elegant. But it must work as described for full credit. Be clear about your indentation! Write legibly!!
9 CSE 231, Spring 09, Dr. Dillon, Exam 1 written solution Name: Section:
10 ASCII Table
Spring Semester 10 Exam #1 Dr. Dillon. (02/18)
Spring Semester 10 Exam #1 Dr. Dillon. (02/18) Form 1 B Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationSpring Semester 11 Exam #1 Dr. Dillon. (02/15)
Spring Semester 11 Exam #1 Dr. Dillon. (02/15) Form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You may use one 8.5"
More informationSpring Semester 13, Dr. Punch. Exam #1 (2/14), form 1 A
Spring Semester 13, Dr. Punch. Exam #1 (2/14), form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationSpring Semester 08, Dr. Punch. Exam #1 (2/12), form 1 B
Spring Semester 08, Dr. Punch. Exam #1 (2/12), form 1 B Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationSpring Semester 09 Exam #2 Dr. Dillon. (04/02)
Spring Semester 09 Exam #2 Dr. Dillon. (04/02) Form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationFall 08, Sherri Goings, Exam #1 (10/2), form 1 B
Fall 08, Sherri Goings, Exam #1 (10/2), form 1 B Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes to complete
More informationSpring Semester 08, Dr. Punch. Exam #1 (2/12), form 1 A
Spring Semester 08, Dr. Punch. Exam #1 (2/12), form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationFirst name (printed): a. DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
CSE 231 F 13 Exam #1 Last name (printed): First name (printed): Form 1 X Directions: a. DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b. This exam booklet contains 25 questions, each
More informationExam 2, Form A CSE 231 Spring 2014 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 30 questions, each of which will be weighted equally at 5 points each.
More informationExam 2, Form B CSE 231 Spring 2014 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 30 questions, each of which will be weighted equally at 5 points each.
More informationExam #1, Form 1 A CSE 231 Spring 2015 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 30 questions, each of which will be weighted equally. The total points
More informationSpring Semester, Dr. Punch. Exam #2 (03/28), form 2 C
Spring Semester, Dr. Punch. Exam #2 (03/28), form 2 C Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 90 minutes to
More informationSpring Semester 16, Dr. Punch. Exam #1 (2/18), form 1 A
Spring Semester 16, Dr. Punch. Exam #1 (2/18), form 1 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 80 minutes
More informationExam #3, Form 3 A CSE 231 Fall 2015 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) Please fill in the requested information at the top of this exam booklet. (3) Use a #2 pencil
More informationFinal Exam, Form 3 A CSE 231 Spring 2015 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) Please fill in the requested information at the top of this exam booklet. (3) Use a #2 pencil
More informationFall Semester, Dr. Punch. Exam #2 (11/07), form 2 A
Fall Semester, Dr. Punch. Exam #2 (11/07), form 2 A Last name (printed): First name (printed): Directions: a) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b) You have 90 minutes to
More informationExam 1, Form A CSE 231 Fall 2012 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 26 questions, each of which will be weighted equally at 5 points each.
More informationFirst name (printed): a. DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
CSE 231 F 13 Exam #2 Last name (printed): First name (printed): Form 2 X Directions: a. DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. b. This exam booklet contains 30 questions, each
More informationExam 3, Form A CSE 231 Spring 2014 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 40 questions, each of which will be weighted equally at 5 points each.
More informationExam 2, Form A CSE 231 Spring 2013 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: Date: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) This exam booklet contains 24 questions, each of which will be weighted equally at 5 points each.
More informationCS110 Introduction to Computing Fall 2006 Midterm Exam
CS110 Introduction to Computing Fall 2006 Midterm Exam Name: This is an open book/notes exam. Sharing of notes and books is not permitted. Answer all questions in the space provided. Continue on back of
More informationCSE 341, Spring 2011, Final Examination 9 June Please do not turn the page until everyone is ready.
CSE 341, Spring 2011, Final Examination 9 June 2011 Please do not turn the page until everyone is ready. Rules: The exam is closed-book, closed-note, except for one side of one 8.5x11in piece of paper.
More informationSpring 2017 CS 1110/1111 Exam 1
CS 1110/1111 Spring 2017 Exam 1 page 1 of 6 Spring 2017 CS 1110/1111 Exam 1 Bubble in your computing ID in the footer of this page. We use an optical scanner to read it, so fill in the bubbles darkly.
More informationCS 115 Exam 1, Fall 2015 Thu. 09/24/2015
CS 115 Exam 1, Fall 2015 Thu. 09/24/2015 Name: Section: Rules and Hints You may use one handwritten 8.5 11 cheat sheet (front and back). This is the only additional resource you may consult during this
More informationCIS 110 Introduction to Computer Programming 8 October 2013 Midterm
CIS 110 Introduction to Computer Programming 8 October 2013 Midterm Name: Recitation # (e.g., 201): Pennkey (e.g., eeaton): My signature below certifies that I have complied with the University of Pennsylvania
More informationEXAMINATION INSTRUCTIONS
Midterm exam CSE5/503 Computer Science I Spring 209 EXAMINATION INSTRUCTIONS This examination has 9 pages. If your copy is missing a page, let one of the course staff know. Before starting this test, students
More informationFinal Exam Version A
CS112 Spring 2014 Dr. Kinga Dobolyi Final Exam Version A Do not open this exam until you are told. Read these instructions: 1. This is a closed book exam. No calculators, notes, or other aids are allowed.
More information1 Truth. 2 Conditional Statements. Expressions That Can Evaluate to Boolean Values. Williams College Lecture 4 Brent Heeringa, Bill Jannen
1 Truth Last lecture we learned about the int, float, and string types. Another very important object type in Python is the boolean type. The two reserved keywords True and False are values with type boolean.
More informationPhysics 3620/6620 Test # 1-1 -
Physics 3620/6620 Test # 1-1 - The test is worth 100 points, but a maximum of 120 points are available Problems 1-3 are worth a maximum of 20 points each, and problem #4, with the VI, is worth a maximum
More informationText Input and Conditionals
Text Input and Conditionals Text Input Many programs allow the user to enter information, like a username and password. Python makes taking input from the user seamless with a single line of code: input()
More informationCS 1301 Exam 1 Fall 2010
CS 1301 Exam 1 Fall 2010 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam in
More informationCS 303E Fall 2011 Exam 2 Solutions and Criteria November 2, Good Luck!
CS 303E Fall 2011 Exam 2 Solutions and Criteria November 2, 2011 Name: EID: Section Number: Friday discussion time (circle one): 9-10 10-11 11-12 12-1 2-3 Friday discussion TA(circle one): Wei Ashley Answer
More informationCS 1301 Exam 1 Fall 2014
CS 1301 Exam 1 Fall 2014 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam in
More informationPREPARING FOR PRELIM 1
PREPARING FOR PRELIM 1 CS 1110: FALL 2012 This handout explains what you have to know for the first prelim. There will be a review session with detailed examples to help you study. To prepare for the prelim,
More informationCIS 110 Introduction to Computer Programming Summer 2018 Final. Recitation # (e.g., 201):
CIS 110 Introduction to Computer Programming Summer 2018 Final Name: Recitation # (e.g., 201): Pennkey (e.g., paulmcb): My signature below certifies that I have complied with the University of Pennsylvania
More informationCS 111X - Spring Final Exam - KEY
CS 111X - Spring 2016 - Final Exam 1/10 Computing ID: CS 111X - Spring 2016 - Final Exam - KEY Name: Computing ID: On my honor as a student, I have neither given nor received unauthorized assistance on
More informationGetting Started. Office Hours. CSE 231, Rich Enbody. After class By appointment send an . Michigan State University CSE 231, Fall 2013
CSE 231, Rich Enbody Office Hours After class By appointment send an email 2 1 Project 1 Python arithmetic Do with pencil, paper and calculator first Idle Handin Help room 3 What is a Computer Program?
More informationCONTROL AND ENVIRONMENTS 1
CONTROL AND ENVIRONMENTS 1 COMPUTER SCIENCE 61A September 1, 2016 1 Control Control structures direct the flow of logic in a program. For example, conditionals (ifelif-else) allow a program to skip sections
More informationEXAMINATION INSTRUCTIONS
Midterm exam CSE115/503 Computer Science I Spring 2019 EXAMINATION INSTRUCTIONS This examination has 9 pages. If your copy is missing a page, let one of the course staff know. Before starting this test,
More informationCSE 131 Introduction to Computer Science Fall Exam I
CSE 131 Introduction to Computer Science Fall 2013 Given: 30 September 2013 Exam I Due: End of session This exam is closed-book, closed-notes, no electronic devices allowed. The exception is the cheat
More informationControl Flow: Loop Statements
Control Flow: Loop Statements A loop repeatedly executes a of sub-statements, called the loop body. Python provides two kinds of loop statements: a for-loop and a while-loop. This exercise gives you practice
More informationCSE 131 Introduction to Computer Science Fall Exam II
CSE 131 Introduction to Computer Science Fall 2013 Given: 6 November 2013 Exam II Due: End of session This exam is closed-book, closed-notes, no electronic devices allowed. The exception is the cheat sheet
More informationCIS 110 Introduction to Computer Programming Summer 2018 Final. Recitation # (e.g., 201):
CIS 110 Introduction to Computer Programming Summer 2018 Final Name: Recitation # (e.g., 201): Pennkey (e.g., paulmcb): My signature below certifies that I have complied with the University of Pennsylvania
More informationCS 111X - Fall Test 1
CS 111X - Fall 2016 - Test 1 1/9 Computing ID: CS 111X - Fall 2016 - Test 1 Name: Computing ID: On my honor as a student, I have neither given nor received unauthorized assistance on this exam. Signature:
More informationCS 1301 Exam 1 Fall 2014
CS 1301 Exam 1 Fall 2014 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam in
More informationCSE 143 Final Exam Part 1 - August 18, 2011, 9:40 am
CSE 143 Final Exam Part 1 - August 18, 2011, 9:40 am Name Student ID # Section TA Name The exam is closed book, closed notes, closed devices, except that you may have a 5x8 card with handwritten notes
More informationCS 115 Exam 2 (Section 1) Spring 2017 Thu. 03/31/2017
CS 115 Exam 2 (Section 1) Spring 2017 Thu. 03/31/2017 Name: Rules and Hints You may use one handwritten 8.5 x 11 cheat sheet (front and back). This is the only additional resource you may consult during
More informationTest #2 October 8, 2015
CPSC 1040 Name: Test #2 October 8, 2015 Closed notes, closed laptop, calculators OK. Please use a pencil. 100 points, 5 point bonus. Maximum score 105. Weight of each section in parentheses. If you need
More informationPart 1 (80 points) Multiple Choice Questions (20 questions * 4 points per question = 80 points)
EECS 183 Fall 2013 Exam 1 Part 1 (80 points) Closed Book Closed Notes Closed Electronic Devices Closed Neighbor Turn off Your Cell Phones We will confiscate all electronic devices that we see including
More informationComputer Science 217
Computer Science 217 Midterm Exam October 29, 2014 First Name: Last Name: ID: Class Time (Circle One): 1:00pm 3:00pm Instructions: Neatly print your names and ID number in the spaces provided above. Pick
More informationCSE341, Spring 2013, Final Examination June 13, 2013
CSE341, Spring 2013, Final Examination June 13, 2013 Please do not turn the page until 8:30. Rules: The exam is closed-book, closed-note, except for both sides of one 8.5x11in piece of paper. Please stop
More informationCS 101, Spring 2016 March 22nd Exam 2
CS 101, Spring 2016 March 22nd Exam 2 Name: Question 1. [3 points] Which of the following loop statements would most likely cause the loop to execute exactly n times? You may assume that n will be set
More informationTopics. Chapter 5. Equality Operators
Topics Chapter 5 Flow of Control Part 1: Selection Forming Conditions if/ Statements Comparing Floating-Point Numbers Comparing Objects The equals Method String Comparison Methods The Conditional Operator
More informationCIS 110 Introduction to Computer Programming Summer 2016 Midterm. Recitation # (e.g., 201):
CIS 110 Introduction to Computer Programming Summer 2016 Midterm Name: Recitation # (e.g., 201): Pennkey (e.g., paulmcb): My signature below certifies that I have complied with the University of Pennsylvania
More informationLecture 11: while loops CS1068+ Introductory Programming in Python. for loop revisited. while loop. Summary. Dr Kieran T. Herley
Lecture 11: while loops CS1068+ Introductory Programming in Python Dr Kieran T. Herley Python s while loop. Summary Department of Computer Science University College Cork 2017-2018 KH (24/10/17) Lecture
More informationCS 1110 Final, December 8th, Question Points Score Total: 100
CS 1110 Final, December 8th, 2016 This 150-minute exam has 8 questions worth a total of 100 points. Scan the whole test before starting. Budget your time wisely. Use the back of the pages if you need more
More informationCS 1301 Exam 1 Fall 2010
CS 1301 Exam 1 Fall 2010 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam in
More informationControl and Environments Fall 2017 Discussion 1: August 30, Control. If statements. Boolean Operators
CS 61A Control and Environments Fall 2017 Discussion 1: August 30, 2017 1 Control Control structures direct the flow of logic in a program. For example, conditionals (if-elif-else) allow a program to skip
More informationKey Differences Between Python and Java
Python Python supports many (but not all) aspects of object-oriented programming; but it is possible to write a Python program without making any use of OO concepts. Python is designed to be used interpretively.
More informationCS 1301 Exam 2 Fall 2010
CS 1301 Exam 2 Fall 2010 Name : Grading TA: Devices: If your cell phone, pager, PDA, beeper, ipod, or similar item goes off during the exam, you will lose 10 points on this exam. Turn all such devices
More informationCS112 Spring 2012 Dr. Kinga Dobolyi. Exam 2. Do not open this exam until you are told. Read these instructions:
CS112 Spring 2012 Dr. Kinga Dobolyi Exam 2 Do not open this exam until you are told. Read these instructions: 1. This is a closed book exam. No calculators, notes, or other aids are allowed. If you have
More informationMidterm Exam 2B Answer key
Midterm Exam 2B Answer key 15110 Principles of Computing Fall 2015 April 6, 2015 Name: Andrew ID: Lab section: Instructions Answer each question neatly in the space provided. There are 6 questions totaling
More informationQuestion Points Score
CS 453 Introduction to Compilers Midterm Examination Spring 2009 March 12, 2009 75 minutes (maximum) Closed Book You may use one side of one sheet (8.5x11) of paper with any notes you like. This exam has
More informationCSEN202: Introduction to Computer Science Spring Semester 2017 Midterm Exam
Page 0 German University in Cairo April 6, 2017 Media Engineering and Technology Faculty Prof. Dr. Slim Abdennadher CSEN202: Introduction to Computer Science Spring Semester 2017 Midterm Exam Bar Code
More informationCIS 110 Introduction to Computer Programming Summer 2018 Midterm. Recitation ROOM :
CIS 110 Introduction to Computer Programming Summer 2018 Midterm Name: Recitation ROOM : Pennkey (e.g., paulmcb): My signature below certifies that I have complied with the University of Pennsylvania s
More information15-110: Principles of Computing Sample Exam #1
15-110: Principles of Computing Sample Exam #1 The following is a "sample exam" that you can use to practice after you have studied for the exam. Keep in mind that the actual exam will have its own questions,
More informationProgramming in Python 3
Programming in Python 3 Programming transforms your computer from a home appliance to a power tool Al Sweigart, The invent with Python Blog Programming Introduction Write programs that solve a problem
More informationCS 1301 Exam 1 Spring 2011
CS 1301 Exam 1 Spring 2011 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam
More informationCS 115 Lecture 8. Selection: the if statement. Neil Moore
CS 115 Lecture 8 Selection: the if statement Neil Moore Department of Computer Science University of Kentucky Lexington, Kentucky 40506 neil@cs.uky.edu 24 September 2015 Selection Sometime we want to execute
More informationCS 1110 Final, December 8th, Question Points Score Total: 100
CS 1110 Final, December 8th, 2016 This 150-minute exam has 8 questions worth a total of 100 points. Scan the whole test before starting. Budget your time wisely. Use the back of the pages if you need more
More informationUniversity of Washington CSE 140 Introduction to Data Programming Winter Midterm exam. February 6, 2013
University of Washington CSE 140 Introduction to Data Programming Winter 2013 Midterm exam February 6, 2013 Name: Solutions UW Net ID (username): This exam is closed book, closed notes. You have 50 minutes
More informationC ONTROL AND H IGHER O RDER F UNCTIONS
Name: Date: Period: Name 2: Name 3: Name 4: 20 points C ONTROL AND H IGHER O RDER F UNCTIONS (Review questions from readings and labs) 1 Instructions: Complete all 9S CIENCE discussion C OMPUTER 61A questions.
More informationPython Activity 5: Boolean Expressions and Selection Statements
Python Activity 5: Boolean Expressions and Selection Statements "True or False and making choices" Learning Objectives Students will be able to: Content: Explain the three types of programming structures
More informationCS 1301 Exam 1 Spring 2014
CS 1301 Exam 1 Spring 2014 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam
More informationFinal Exam COMP Fall 2004 Dec 16, 2004
1. Closed book and closed notes. Final Exam COMP 14-062 Fall 2004 Dec 16, 2004 2. Write all scratch work and answers on the exam itself. If you need extra space, let me know. Indicate your final answer
More informationProblem Score 1 / 27 2 / 19 3 / 16 4 / 14 code check off 5 / 22 /2 Total /100
ME430 Mechatronics Examination I Page 1 Name CM Section You may use only: ME430 Mechatronics Examination I Sept 22nd, 2016 Problem Score 1 / 27 2 / 19 3 / 16 4 / 14 code check off 5 / 22 /2 Total /100
More informationCSE 131 Introduction to Computer Science Fall 2016 Exam I. Print clearly the following information:
CSE 131 Introduction to Computer Science Fall 2016 Given: 29 September 2016 Exam I Due: End of Exam Session This exam is closed-book, closed-notes, no electronic devices allowed The exception is the "sage
More informationCS134 Spring 2005 Final Exam Mon. June. 20, 2005 Signature: Question # Out Of Marks Marker Total
CS134 Spring 2005 Final Exam Mon. June. 20, 2005 Please check your tutorial (TUT) section from the list below: TUT 101: F 11:30, MC 4042 TUT 102: M 10:30, MC 4042 TUT 103: M 11:30, MC 4058 TUT 104: F 10:30,
More informationEXAM Computer Science 1 Part 1
Maastricht University Faculty of Humanities and Science Department of Knowledge Engineering EXAM Computer Science 1 Part 1 Block 1.1: Computer Science 1 Code: KEN1120 Examiner: Kurt Driessens Date: Januari
More informationUNCA CSCI 255 Exam 1 Spring February, This is a closed book and closed notes exam. It is to be turned in by 1:45 PM.
UNCA CSCI 255 Exam 1 Spring 2017 27 February, 2017 This is a closed book and closed notes exam. It is to be turned in by 1:45 PM. Communication with anyone other than the instructor is not allowed during
More informationPractice Midterm Examination
Nick Troccoli Practice Midterm CS 106A July 18, 2017 Practice Midterm Examination Midterm Time: Monday, July 24th, 7:00P.M. 9:00P.M. Midterm Location: Hewlett 200 Based on handouts by Mehran Sahami, Eric
More informationPrelim 1. CS 2110, 13 March 2018, 7:30 PM Total Question Name Short answer
Prelim 1 CS 2110, 13 March 2018, 7:30 PM 1 2 3 4 5 6 Total Question Name Short answer Exception handling Recursion OO Loop invariants Max 1 30 11 14 30 14 100 Score Grader The exam is closed book and closed
More informationCIS 110 Introduction to Computer Programming Spring 2016 Midterm
CIS 110 Introduction to Computer Programming Spring 2016 Midterm Name: Recitation # (e.g., 201): Pennkey (e.g., eeaton): My signature below certifies that I have complied with the University of Pennsylvania
More informationComputer Science 217
Computer Science 17 Midterm Exam March 5, 014 Exam Number 1 First Name: Last Name: ID: Class Time (Circle One): 1:00pm :00pm Instructions: Neatly print your names and ID number in the spaces provided above.
More informationCS 111X - Fall Test 1 - KEY KEY KEY KEY KEY KEY KEY
CS 111X - Fall 2016 - Test 1 1/9 Computing ID: CS 111X - Fall 2016 - Test 1 - KEY KEY KEY KEY KEY KEY KEY Name: Computing ID: On my honor as a student, I have neither given nor received unauthorized assistance
More informationControl and Environments Fall 2017 Discussion 1: August 30, 2017 Solutions. 1 Control. If statements. Boolean Operators
CS 61A Control and Environments Fall 2017 Discussion 1: August 30, 2017 Solutions 1 Control Control structures direct the flow of logic in a program. For example, conditionals (if-elif-else) allow a program
More informationFlow of Control. 2.1 The if Statement
Flow of Control 2 In almost any computer program written for a scientific computing application, we need to allow the computer to execute a collection of statements if and only if some criterion is met.
More informationCSCE 110: Programming I
CSCE 110: Programming I Sample Questions for Exam #1 February 17, 2013 Below are sample questions to help you prepare for Exam #1. Make sure you can solve all of these problems by hand. For most of the
More informationExam 1 Practice CSE 232 Summer 2018 (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN.
Name: Section: INSTRUCTIONS: (1) DO NOT OPEN YOUR EXAM BOOKLET UNTIL YOU HAVE BEEN TOLD TO BEGIN. (2) The total for the exam is 100 points (3) There are 8 pages with 32 problem; 15 multiple-choice, 15
More informationCS 1301 Exam 1 Spring 2014
CS 1301 Exam 1 Spring 2014 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam
More informationCS 1110 Prelim 1 October 17th, 2013
CS 1110 Prelim 1 October 17th, 2013 This 90-minute exam has 6 questions worth a total of 100 points. Scan the whole test before starting. Budget your time wisely. Use the back of the pages if you need
More informationExam 1 Format, Concepts, What you should be able to do, and Sample Problems
CSSE 120 Introduction to Software Development Exam 1 Format, Concepts, What you should be able to do, and Sample Problems Page 1 of 6 Format: The exam will have two sections: Part 1: Paper-and-Pencil o
More informationEXAMINATION FOR THE BSC (HONS) INFORMATION SYSTEMS; BSC (HONS) INFORMATION TECHNOLOGY & BSC (HONS) COMPUTER SCIENCE; YEAR 1
FACULTY OF SCIENCE AND TECHNOLOGY EXAMINATION FOR THE BSC (HONS) INFORMATION SYSTEMS; BSC (HONS) INFORMATION TECHNOLOGY & BSC (HONS) COMPUTER SCIENCE; YEAR 1 ACADEMIC SESSION 2014; SEMESTER 1 & 2 FINAL
More informationCrash Dive into Python
ECPE 170 University of the Pacific Crash Dive into Python 2 Lab Schedule Today Ac:vi:es Endianness Python Thursday Network programming Lab 8 Network Programming Lab 8 Assignments Due Due by Mar 30 th 5:00am
More informationYou may not share any information or materials with classmates during the exam and you may not use any electronic devices.
ICS 31 UC IRVINE FALL 2012 DAVID G. KAY YOUR NAME YOUR LAB: YOUR STUDENT ID (8 DIGITS) SECTION (1-10) YOUR UCINET ID TIME MWF AT: 8 10 12 2 4 6 TA S NAME Second Midterm You have 75 minutes (until the end
More information60th ANNUAL HIGH SCHOOL HONORS MATHEMATICS CONTEST
60th ANNUAL HIGH SCHOOL HONORS MATHEMATICS CONTEST April, 017 on the campus of the University of California, San Diego PART I 5 Questions Welcome to the contest! Please do not open the exam until told
More informationComputer Science 217
Computer Science 217 Midterm Exam Fall 2012 November 1, 2012 Name: ID: Class Time (Circle One): 1:00pm 3:00pm Instructions: Neatly print your name and ID number in the spaces provided above. Pick the best
More informationProblem Points Score Grader Total 75
University of Illinois at Urbana-Champaign Department of Computer Science First Examination Fall 2010 CS 125 Introduction to Computer Science 90 minutes permitted First name: Last name: NetID: @ illinois.edu
More informationCS 1301 Exam 1 Fall 2011
CS 1301 Exam 1 Fall 2011 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam in
More informationCS 2316 Exam 1 Spring 2014
CS 2316 Exam 1 Spring 2014 Name : Grading TA: Integrity: By taking this exam, you pledge that this is your work and you have neither given nor received inappropriate help during the taking of this exam
More information