









Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!










What is the purpose of relational operators?
Answer: They test the relationship between two variables, expressions, or values.
What do relational operators evaluate to?
Answer: A Boolean value.
What does the expression 'a = b' evaluate to?
Answer: True if a and b are equal; otherwise false.
What does the NOT operator do?
Answer: Evaluates to true if the condition is false; otherwise false.
When does 'condition1 AND condition2' evaluate to true?
Answer: If both condition1 and condition2 are true.
When does 'condition1 OR condition2' evaluate to true?
Answer: If either condition1 or condition2 is true, or both are true.
What happens if a Boolean expression evaluates to true in an IF statement?
Answer: The code in the block of statements is executed.
What is the function of the ELSE statement in an IF-ELSE structure?
Answer: It executes the second block of statements if the condition is false.
What does the REPEAT UNTIL statement do?
Answer: Repeats the block of statements until the Boolean expression evaluates to true.
What is the result of accessing aList[i]?
Answer: It accesses the element of aList at index i.
What does the INSERT function do?
Answer: Shifts values in aList to the right and places value at index i.
What does the APPEND function do?
Answer: Increases the length of aList by 1 and places value at the end.
What happens when REMOVE is called on aList?
Answer: Removes the item at index i and shifts values left.
What does LENGTH(aList) return?
Answer: The number of elements in aList.
What does the FOR EACH loop do?
Answer: Assigns the value of each element of aList to the variable item sequentially.
What is a procedure in programming?
Answer: Defines a block of statements that can take arguments and be called.
What does the RETURN statement do in a procedure?
Answer: Returns the flow of control to the calling statement and returns a value.
What does the robot do in the context provided?
Answer: Moves one square forward in the direction it is facing.
What is the syntax for defining a procedure?
Answer: PROCEDURE procName(parameter1, parameter2, ...) { }.
How can a procedure be called?
Answer: Using the notation procName(arg1, arg2, ...).
What is the eligibility criteria for a ride at an amusement park?
Answer: Must be at least 12 years old and between 50 and 80 inches tall.
What expression evaluates to true for ride eligibility?
Answer: (age >= 12) AND (height >= 50 AND height <= 80)
What are the final values of first and second after executing the code segment?
Answer: first = 200, second = 100
What best explains the relationship between the Internet and the World Wide Web?
Answer: The Internet is a network of interconnected networks, and the World Wide Web is a system of linked pages accessed via the Internet.
Which code segment displays the output 'up down down down up down down down'?
Answer: REPEAT 2 TIMES DISPLAY 'up' REPEAT 3 TIMES DISPLAY 'down'
What exemplifies multifactor authentication in online banking?
Answer: After entering a password, a user must also enter a code sent to their phone.
What is the initial action in the game played on the board?
Answer: Place a game piece on a space that is not red and set a counter to 0.
What happens if the game piece is on a yellow space?
Answer: Move the game piece 3 positions to the left.
What is the value of the counter if the game piece starts on the rightmost black space?
Answer: The counter will be 3 at the end of the game.
What is a direct benefit of using redundant routing on the Internet?
Answer: Redundancy allows messages to be sent even if some devices or connections fail.
How is an analog audio signal typically represented by a computer?
Answer: An analog audio signal is measured at regular intervals, with each measurement stored as a sample represented as a sequence of bits.
What is the decimal value for the jump control?
Answer: 24
What control is represented by the decimal value 15?
Answer: ↓
What can the robot move into?
Answer: The robot can move into a white or gray square.
What does the procedure goalReached evaluate to?
Answer: True if the robot is in the gray square, false otherwise.
Which is NOT a benefit of collaborating to develop a computing innovation?
Answer: Collaboration eliminates the need to resolve differences of opinion.
What change is needed for the program to check if a list of numbers is increasing?
Answer: In line 3, 2 should be changed to 1.
What does the drawLine procedure do?
Answer: Draws a line segment on a coordinate grid with specified endpoints.
Which code segment can be used to draw the figure with 5 line segments?
Answer: xVal ←1; yVal ←0; len ←1; REPEAT 5 TIMES { drawLine(xVal, yVal, xVal, yVal + len); xVal ← xVal + 1; len ←len + 1; }
What are the consequences of publishing an e-book with a no- rights-reserved Creative Commons license?
Answer: Individuals can freely distribute or use the contents without needing additional permissions from the author.
What is the minimum number of connections that must be broken for device B to no longer communicate with device C?
Which strategy is least likely to introduce bias in a social media application?
Answer: Inviting a random sample of all users to try out the new algorithm and provide feedback before it is released to a wider audience.
What does an oval represent in a flowchart?
Answer: The start or end of the algorithm.
What does a rectangle represent in a flowchart?
Answer: One or more processing steps, such as a statement that assigns a value to a variable.
What does a diamond represent in a flowchart?
Answer: A conditional or decision step.
What does a parallelogram represent in a flowchart?
Answer: Displays a message.
What initial values of j and k will cause an infinite loop in the algorithm?
Answer: j = 0, k = 5
What value is displayed if j is 3 and k is 4?
Answer: 9
How is data transmitted on the Internet?
Answer: Data is broken into packets, which can be sent along different paths.
What is the relationship between a binary number and its transformed version after appending three 0s?
Answer: The transformed number is 8 times the value of the original number.
What does public key encryption enable?
Answer: It enables secure communications through an open medium.
How does Algorithm II categorize in route delivery?
Answer: It uses a heuristic approach to provide an approximate solution in reasonable time.
What change ensures a correct simulation of the experiment in the code segment?
Answer: Replacing line 9 with ELSE
In how many of the past ten years were there more than one million moving violations?
Answer: What question cannot be answered with the traffic ticket database?
What is the least likely reason personal information is hard to remove from the Internet?
Answer: All personal information is stored online using authentication measures.
Which value is NOT displayed by the program in the nested code?
Answer: carrot
In what situation is using a simulation least suitable for solving a problem?
Answer: When the problem requires precise measurements and real-world data.
What is the minimum number of bits required for each binary sequence if a store has between 75 and 100 items?
Answer: 7
Which activity has the greatest potential to contribute to the digital divide?
Answer: Requiring applicants for government jobs to apply using an online platform
What solution uses crowdsourcing to encourage respectful communication in online games?
Answer: The company allows individual players to endorse fellow players based on courteous interactions.
Answer: 2
How many squares does the robot move to the right after moving upwards?
Answer: 4
How many squares does the robot move upwards before ending?
Answer: 3
What is the result of the code segment that includes a procedure named botStepper?
Answer: It moves the robot according to specified steps.
What is the total number of items in the inventory if the store has between 75 and 100 items?
Answer: Between 75 and 100.
What is the purpose of the procedure 'botStepper'?
Answer: To move the robot forward a specified number of times.
What is the average customer rating for Delicious Sub Shop II?
Answer: 4.
How many customer ratings does Rustic Farm Tavern have?
Answer: 116
What is the price range for 78th Street Bistro?
Answer: med
What is the customer rating for Seaside Taqueria?
Answer: 4.
What is the price range for Delicious Sub Shop II?
Answer: lo
What is the price range for Rustic Farm Tavern?
Answer: hi
Does Seaside Taqueria accept credit cards?
Answer: Yes
What is the price range for ABC Downtown Diner?
Answer: med
What is the average customer rating for Joey Calzone's Pizzeria?
Answer: 3.
How many customer ratings does Seaside Taqueria have?
Answer: 214
Does Rustic Farm Tavern accept credit cards?
Answer: Yes
What does 'lo' indicate in the price range?
Answer: Under $
What does 'med' indicate in the price range?
Answer: $11 to $
What does 'hi' indicate in the price range?
Answer: Over $
What is the first step to identify restaurants that accept credit cards with the greatest average rating?
Answer: Filter by number of ratings
What is the second step after filtering by number of ratings?
Answer: Filter by payment type
What is the intended transformation of the list utensils?
Answer: Move the last element to the beginning.
Which code segment correctly transforms the list utensils?
Answer: Option (C): temp ← utensils[len]; REMOVE(utensils, len); INSERT(utensils, 1, temp)
What information does Spreadsheet I contain?
Answer: Student name, student ID, and grade point average.
What does Spreadsheet II contain?
Answer: Information on students who play at least one sport, including student ID and sports names.
What does Spreadsheet III include?
Answer: Information on students with a GPA greater than 3.5, including student name and ID.
What does Spreadsheet IV contain?
Answer: Information on students who play more than one sport, including student name and ID.
Which spreadsheets can be combined to analyze GPA of athletes?
Answer: Option (C): Spreadsheets II and III.
What is the execution time of process P?
Answer: 30 seconds.
What is the execution time of process Q?
Answer: 10 seconds.
What is the execution time of process R?
Answer: 20 seconds.
What is the execution time of process S?
Answer: 15 seconds.
Which parallel computing solution minimizes execution time?
Answer: Option (B): Running processes P and R on one processor and Q and S on the other.
What data must be collected for RunRoutr to suggest a running route?
Answer: The user's geographic position.
What data is necessary to share Adrianna's running route?
Answer: The current locations of other RunRoutr users.
What is a likely benefit of the RunRoutr application?
Answer: Users may see health benefits from exercising together.
What is a data privacy concern for RunRoutr users?
Answer: Users may determine information about locations of users not on their contact lists.
Which group is least likely to receive targeted advertisements?
Answer: Individuals who sign up for a premium account.
What are the equivalent expressions for the value of expression based on the table?
Answer: Options (A) and (D): (NOT input1) OR (NOT input2) and NOT (input AND input2).
What age group is considered a minor?
Answer: People who are under 18.
What age group is considered a senior citizen?
Answer: People who are 65 and older.
For which contents of myList will the duplicate removal procedure NOT work as intended?
Answer: A) [10, 10, 20, 20, 10, 10], D) [50, 50, 50, 50, 50, 50]
What type of data does each photo file contain for a science project about weather patterns?
Answer: Data representing the level of red, green, and blue for each pixel, along with metadata.
When is analyzing metadata more appropriate than analyzing pixel data?
Answer: A) Determining the chronological order of the photos, D) Determining whether two photos were taken at the same location on different days.
What does the substring procedure do?
Answer: Returns a substring of consecutive characters of str from start to end.
What does the concat procedure do?
Answer: Returns a single string consisting of str1 followed by str2.
What does the len procedure return?
Answer: The number of characters in a string.
How can a programmer create a new string by removing a character at position n from oldStr?
Answer: By using substring and concat procedures.
What is the correct way to create newStr by removing the character at position n?
Answer: A) left ← substring(oldStr, 1, n - 1); right ← substring(oldStr, n + 1, len(oldStr)); newStr ← concat(left, right).
What is phishing?
Answer: A technique that attempts to trick a user into providing personal information.
What must be true for a person to be eligible for a ride based on age and height?
Answer: Age must be ≥ 12 and height must be ≥ 50 and ≤ 80.
What is the difference between the Internet and the World Wide Web?
Answer: The Internet is a network of interconnected networks; the World Wide Web is an information system accessed via the Internet.
What is the initial value of the variable first in the code segment?
Answer: 100
What is the initial value of the variable second in the code segment?
Answer: 200
What happens to the variable first after executing the code segment?
Answer: Both first and second have the value 100.
◉