CS 1010 Midterm: CS 101 UVA Exam2

16 views10 pages

Document Summary

This exam is open text book but closed-notes, closed-calculator, closed-neighbor, etc. Questions are worth different amounts (in particular, the final two questions are worth substantially more than any other questions), so be sure to look over all the questions and plan your time accordingly. Note: when an integer type is required use int, when a floating-point type is required use double. Note: the last two pages are for additional space to use on any problem. _______: (3 points) what is the output of the following code segment? int i = 5; Email id: _______: (5 points) the following code has a bug: If no , why not? (b) describe how to fix the bug and give the output of the code after the bug is fixed. Email id: _______: (12 points) consider the following code segment. a, b, c, and d are boolean variables:

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers

Related Documents