Computer Science



Item Name

1. All information used by a computer is represented using

1. All information used by a computer is represented using _____________ notation. 2. The _____________ phase of the software life cycle is also called the coding phase. 3. More than half of the cost of developing software goes to the _____________ phase of the software life cycle. 4. ACM stands for _____________. 5. Copyright law is designed to give fair use to the public and to protect the...

1. An apostrophe (') in code marks the beginning of

1. An apostrophe (') in code marks the beginning of a ________________________. 2. The equal sign (=) is known as the ________________________ operator. It copies the value on its right into the item on its left. 3. In an assignment statement, the name of the item receiving the value must be on the ________________________ side of the = operator. 4. The ________________________ control docks at...

1. Dim intReadings(-99) As Integer 2. Dim intTable(10) As Integer

1. Dim intReadings(-99) As Integer 2. Dim intTable(10) As Integer ' Stores 11 values Dim intIndex As Integer Dim intMaxNum As Integer = 11 For intIndex = 0 To intMaxNum intTable(intIndex) = CInt(InputBox("Enter the next value:")) Next 3. Dim intValues(3) = { 2, 4, 6 } 4. ' tmrTimer is a Timer control tmrTimer.Interval = 0

1. For the following function, def hours_of_daylight(month, year

1. For the following function, def hours_of_daylight(month, year) (a) Give an appropriate docstring specifi cation where hours_of_daylight returns the total number of hours of daylight for the month and year given (each passed an integer value) designed so that the function does not check for invalid parameter values. (b) Give a print statement that displays the docstring for this function.

1. In contrast to terminal I/O programs, GUI programs are

1. In contrast to terminal I/O programs, GUI programs are driven__________. 2. A button allows the user to select a(n) __________ . 3. Two types of window objects that support numeric I/O are a(n) __________and a(n) __________ . 4. A window object that supports the I/O of a single line of text is a(n) __________ . 5. A separate window that pops up with information is a(n) __________ .

1. In mixed-mode arithmetic with operand types int and double,

1. In mixed-mode arithmetic with operand types int and double, the result type is always ________. 2. A method’s name, parameters, and return type are also known as its ________. 3. The operation that joins two strings together is called ________. 4. End-of-line comments begin with the symbol ________. 5. A quotient results when the ________operator is used with two operands of type________.

1. In the obama_vs_mccain dataset, find the (Pearson) correlation between

1. In the obama_vs_mccain dataset, find the (Pearson) correlation between the percentage of unemployed people within the state and the percentage of people that voted for Obama. [5] 2. Draw a scatterplot of the two variables, using a graphics system of your choice. (For bonus points, use all three systems.) [10] for one plot, [30] for all three

1. Load the hafu dataset from the learningr package. In

1. Load the hafu dataset from the learningr package. In the Father and Mother columns, some values have question marks after the country name, indicating that the author was uncertain about the nationality of the parent. Create two new columns in the hafu data frame, denoting whether or not there was a question mark in the Father or Mother column, respectively. 2. Remove those question marks from...

1. Methods and variables that belong to a class rather

1. Methods and variables that belong to a class rather than an instance are called_________ or_________ variables and methods. 2. The keyword used to invoke a constructor or method in a superclass is called_________ . 3. The visibility modifier_________ makes a method or variable visible to subclasses but not to other clients. 4. A(n) _________ class contains common behavior and data for a set of...

1. OOP stands for________ . 2. The software responsible for

1. OOP stands for________ . 2. The software responsible for translating a program in a high-level language to machine code is called a(n) ________ . 3. JVM stands for________ . 4. When an object receives a message, the object responds by running a block of code called a(n) ________ . 5. Numbers with a fractional part are called________ . 6. When evaluating an expression, Java performs operations...