WGU C949 - DATA STRUCTURES AND ALGORITHMS EXAM | OBJECTIVE ASSESSMENT |, Exams of Nursing

WGU C949 - DATA STRUCTURES AND ALGORITHMS EXAM | OBJECTIVE ASSESSMENT | {LATEST 2026/ 2027 UPDATE} COMPLETE ACTUAL AND AUTHENTIC EXAM | BRAND NEW!

Typology: Exams

2025/2026

Available from 05/14/2026

Bestpdfseller
Bestpdfseller 🇺🇸

2.3

(3)

4K documents

1 / 74

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Page 1 of 74
WGU C949 - DATA STRUCTURES AND
ALGORITHMS EXAM | OBJECTIVE
ASSESSMENT | {LATEST 2026/ 2027 UPDATE}
COMPLETE ACTUAL AND AUTHENTIC EXAM |
BRAND NEW!
How many times will count++ execute when i = 3, in this pseudocode?
int count = 0;
int N = 4;
for (int i = 0; i < N; i++)
for (int j = 0; j < i; j++)
count++;
3
What is the most efficient data type to use for this data set of a fixed
size in Java?
a = [0, 0, 1, 4, 7, 16, 31, 64, 127]
Array
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a
pf3b
pf3c
pf3d
pf3e
pf3f
pf40
pf41
pf42
pf43
pf44
pf45
pf46
pf47
pf48
pf49
pf4a

Partial preview of the text

Download WGU C949 - DATA STRUCTURES AND ALGORITHMS EXAM | OBJECTIVE ASSESSMENT | and more Exams Nursing in PDF only on Docsity!

WGU C949 - DATA STRUCTURES AND

ALGORITHMS EXAM | OBJECTIVE

ASSESSMENT | {LATEST 2026/ 2027 UPDATE}

COMPLETE ACTUAL AND AUTHENTIC EXAM |

BRAND NEW!

How many times will count++ execute when i = 3, in this pseudocode? int count = 0; int N = 4; for (int i = 0; i < N; i++) for (int j = 0; j < i; j++) count++; 3 What is the most efficient data type to use for this data set of a fixed size in Java? a = [0, 0, 1, 4, 7, 16, 31, 64, 127] Array

What is true about garbage collection? It reclaims memory from data structures implemented using linked allocations. What is true about a data structure implemented using linked allocation? Storage is allocated using pointers to new locations as needed. What are the array elements corresponding to the mid-values in the first and second iterations of a binary search in an array arr = {45, 77, 89, 90, 94, 99, 100} and key = 100? 90 and 99 What is the effect on the object Computing regarding garbage collection? Computing obj = new Computing(); obj = null; It is automatically available for garbage collection.

dict = {'white':0x0000, 'black':0x1111} Which command/function generates the output ['white','black']? dict.keys() Items were added sequentially in this stack starting with 'ham': 'sausage' 'toast' 'eggs' 'ham' What is the correct order of contents after the push operation is performed with the value 'bacon'? 'bacon' 'sausage' 'toast' 'eggs' 'ham'

Items were added sequentially in this stack starting with "dog": "bird" "rabbit" "cat" "dog" What is the return value of the pop operation? "bird" Which sequence of letters represents preorder traversal of the nodes of this tree? A / B C / / D E \ / F G H /

'yellow' 'blue' 'red' What could be the stack after a push operation? ['red','blue','yellow', 'green', 'purple"] Items were added sequentially onto the stack starting with 'red': 'green' 'yellow' 'blue' 'red' What is the stack after a pop operation? 'yellow' 'blue' 'red'

Which command helps to speed up comparisons using dictionary keys during a dictionary (d) lookup in this pseudocode clip? h = hash(key) for pair in d: if h == pair[0]: return pair[1] hash(object) What does the method any(b) return in Python if b is a dictionary? Returns True if any key of the dictionary is true. Which Java method is used to read bytes from a standard file? Java.io.FileInputStream Which command will retrieve an item from the top of the stack? Pop()

Which data structure uses a last in, first out (LIFO) removal of items? Stack Given: heapList = [22, 33, 44, 55, 66] Which index is the right child of item 22? 44 What is the logical first step in an algorithm that extracts all the positive values from a given list of numbers? Initialize the result to an empty list What is displayed when n = 2 in this pseudocode? for(int i = 2; i <= n; i++){ for(j = 0; j <= n;){ display j;

j = j + n/2; the division is integer division, decimal part neglected } } 0, 1, 2 Given a set of numeric data and two declared variables: small and max, what is the logical first step in an algorithm that finds the smallest number? Checking that the list contains at least one number What is the output of the pseudocode below if the variables declared in the main program are global? Main Declare X as Integer, Y as Integer Set X = 1 Set Y = 2 Call Sub(X, Y) Write X Write Y End Program

If N == 1 Then Set F = 1 Else Set F = N * F(N - 1) Set N = N - 1 End If End Function 3 What is displayed in Step 5 if A = 15 and B = 5 in the pseudocode below? Step 1: Start Step 2: Read A, B Step 3: C= A*B Step 4: D=A/B Step5: Print C Step 6: Stop 75

What is displayed in step 3 if midterm = 60 and final = 65 in this pseudocode? Step 1: Declare midterm, final as integer Step 2: average = (midterm+final)/ Step 3: if (average < 50) then Print "Fail" Else Print "Pass" endif Pass Which statement describes a queue data structure? It is a sequence of elements in which insertions can take place only at the back end and deletions can take place only at the front end. What are the official indexes for the list list01 given this declaration? int[ ] list01 = {0, 2, 4, 6, 8, 10}; 0, 1, 2, 3, 4, 5

Double Which value is appropriate for the variable middle given the pseudocode? function mystery() { string last; string first; char middle; int phone; float rate; } 'D' At the end of obj, what is the time complexity of inserting in this pseudocode? void DynamicArrayAppend(DynamicArray obj, const void input) { if (obj->logicalSize == obj->capacity - 1) {

obj->capacity *= 2; obj->internalArray = realloc(obj->internalArray, obj->capacity * obj- >itemSize); } obj->logicalSize += 1; DynamicArraySet(obj, obj->logicalSize - 1, input); } DynamicArray *obj = DynamicArrayCreate(sizeof(int));for (int i = 0; i < n; i++) { int number = rand() % 10; DynamicArrayAppend(obj, &number); } O(1) or O(n) What is the time complexity of this pseudocode? double sumCol(double table[][], int numRows, int numCols, int col) { double cSum = 0; for (int row = 0; row < numRows; row++) { cSum += table[row][col]; }

s=A[1] for i=1 to n do s=s+A[i] return s O(n) What is the time complexity of this pseudocode? Algorithm Algo3(A, B) Input: Arrays A and B, each of them storing n≥1 integers Output: Count array B[i], where B[i] equals the sum of A[1] to A[i], i= to n c= for i=1 to n do for j=1 to n do s=A[1] for k=1 to j do s=s+A[k] if B[i]=s then c=c+

return c O(n^3) What is an attribute of a bubble sort algorithm? Ideal for small number of n What is a characteristic of quick sort? Recursively breaks down a problem into two or more subproblems of the same or related type Which Big-O notation represents the time complexity of a bubble sort? O(n^2) What is the typical run time for an insertion sort? O(n^2)