Overall Score: 52/70
I think I got a lower score because I felt rushed trying to finish this long mc in just one class period.
Question 3
I chose option D but the correct one was A. The variable second was 200, though it points to temp, which is 100, meaning that the actual value would be 100, rather than 200. This is why option A is correct.
Question 10
For this one I miscalulated. 48 would be 110000, the rigth answer would be 24 which is C.
Question 12
Option B would not code segment continues in an infinite loop but the robot would not be able to move forward. But option C would eventually get the robot in the correct box.
Question 14
B is wrong because with this change, if the method finds a number that is bigger than or the same as the one before it, it will say true right away and won’t look at any more numbers.
Question 17
B is correct since for Devices B and C to stop communicating, they must be totally disconnected from one another. Device B and Device C can still communicate even if any three connections are removed.
Question 22
Option A would be correct becasue the code segment starts count at 1 and increments it after the outer loop. The robot travels 1 square forward, rotates left, then 2 squares forward, 3 squares forward, 4 squares forward, then turns left. Robots exit the grid looking up in the lower right corner. It initializes count to 0 and increments it to start the outer loop. Since count is initialized to 0 and incremented immediately, the inner loop iterates the same number of times as the outer loop in the supplied code. Robots exit the grid looking up in the lower right corner.
Question 26
Option A would be correct since each step is dependent on the step that happens before it, then each step has towait for the first step step to complete before starting the next one.
Question 28
The rigth answer would be j = 5, k = -5, inside the loop, the number of k is decreased by 1 over and over until k = 0. If k is negative at the start, it will keep going down until it reaches 0.
Question 32
Public-key encryption keeps the internet secure which is why A would be correct. It makes sure unauthirzed users are not able to go into something they do not have acess to.
Question 45
OPtion C is correct because the first call to botStepper moves the robot forward two squares, rotates it left so that it faces toward the top of the grid, moves it forward two squares, and rotates it right so that it faces right. The code segment then moves the robot forward one square. The second call to botStepper moves the robot forward three squares, rotates it left so that it faces toward the top of the grid, moves it forward three squares, and rotates it right so that it faces right. The robot ends in the gray square. Option A is wrong because the first call to botStepper moves the robot forward two squares, rotates it left so that it faces toward the top of the grid, moves it forward two squares, and rotates it right so that it faces right. The second call to botStepper moves the robot forward three squares, rotates it left so that it faces toward the top of the grid, moves it forward three squares, and rotates it right so that it faces right. The robot ends one square to the left of the gray square.
Question 48
In option C, tricking a user into providing personal information is an example of a phishing attack, but it doesn’t directly gather personal information. But option A is correct since the rogue access point is a wireless access point that gives unauthorized access to secure networks. Data sent over public networks can be intercepted, analyzed, and modified.
Question 53
Option A is correct because Step 4 checks every element of the list, gradually count each time target appears
Question 54
Option B is correct is the data captured each time a truck enters or leaves the depot do not include any information about the number of customers
Question 55
Option D causes an error because there is no longer an element at index len. Option C would be the correct one because inserts temp as the first element of the list.
Question 57
Option A is correct since to run tasks R and S on the other processor, it will take 35 seconds all together. All four tasks are finished in 40 seconds because the processors work together.
Question 68
B and D both contain no duplicates, which is why A and C would be correct since the question is asking NOT.
Question 70
The correct answer would be C instead of B since this piece of code gives the characters to the left of place n to the variable newStr.