FINAL EXAM 2026 WITH 300+ PREP
QUESTIONS AND WELL-VERIFIED
CORRECT ANSWERS | ALREADY GRADED
A+ | GUARANTEED PASS | COMPUTER
SCIENCE LATEST EXAM 2026 [BRAND
NEW]
What is a primitive data type?
A data type that can only contain one value
What is a composite/compound data type?
A data type built by combining primitive data types, e.g. a class.
What is a data structure?
A collection of data that is organised to allow efficient processing.
What is an abstract data type?
,A conceptual model that describes how data is organised and which operations
can be carried out on the data, with no information as to how this is
implemented.
What is a static data structure?
A data structure that reserves memory for a set amount of data, e.g. a fixed-size
array
What is a dynamic data structure?
A memory efficient data structure which changes in size dynamically.
What are some disadvantages of a dynamic data structure versus a static data
structure?
- Accessed by memory location rather than index, which is sequential, so can
take longer to access data.
- Additiomal memory is needed for pointers.
What is a disadvantage of a static data structure verus a dynamic data structure?
A static data structure can waste memory if it isn't all used, e.g. if an array is
initialized with size 100, but only 10 elements are stored.
What is a queue?
A FIFO (first in, first out) abstract data type.
,How does a queue work?
A pointer to the front of the queue is maintained, as well as one to the rear.
What is a priority queue?
A queue where each element has a priority. Elements are inserted into the queue
depending on their priority relative to the current elements.
What are the main operations available on a queue?
- Enqueue
- Dequeue
- IsEmpty
- IsFull
Time complexity of a linear search
O(n)
Prerequisite of a binary search
The list must be ordered.
Time complexity of a binary search
O(log n)
, Binary search method
- Choose the middle item in the list
- If the item is the target, the search is complete
- Otherwise, if the target is greater than the middle item, discard the lower half
of the list. Else, discard the higher half.
A binary search tree is an example of which type of tree?
Rooted tree
Time complexity of a bubble sort
O(n^2)
Time complexity of a merge sort
O(n log n)
Steps of a merge sort
- Split the list into two lists
- Continue until there are only lists of size 1
- Combine lists in order
How are signed numbers stored using two's complement?
The first bit is negative