What is abstraction?
Abstraction is the process of filtering out unnecessary details in order to focus on the most important aspects of a problem or system.
What is a variable and how is it used in programming?
A variable is a named storage location that can hold a value or reference. In programming, variables are used to store and manipulate data, and can be used to pass data between different parts of a program.
What is the binary search algorithm, and how does it work?
The binary search algorithm is a search algorithm used to find a specific value in a sorted list or array. It works by repeatedly dividing the search interval in half and comparing the middle value to the target value until the target value is found or the interval is empty.
What is the purpose of a compiler?
To translate high-level code into machine code that can be executed by a computer.
What is a key difference between a high-level programming language and a low-level programming language?
High-level programming languages are more abstract and provide more built-in functionality, while low-level programming languages are closer to the machine code and provide more direct control over hardware.
How is logical thinking used in computational thinking?
It is used in computational thinking to help identify inconsistencies or errors in code, as well as to develop algorithms and decision-making systems.
What is iteration and how is it used in programming?
Iteration is a control structure that allows a program to repeat a set of instructions multiple times. In programming, iteration can be used to iterate over arrays or other collections of data, as well as to repeat certain calculations or operations.
What is a queue data structure, and how is it different from a stack?
A queue is a linear data structure that follows a first-in, first-out (FIFO) ordering. Elements are added to the back of the queue and removed from the front. This is different from a stack, which follows a last-in, first-out (LIFO) ordering. Elements are added to the top of the stack and removed from the top.
What is recursion?
A programming technique in which a function calls itself.
What is a control unit?
The part of a CPU that manages the flow of data and instructions
What are two benefits of thinking concurrently in computational thinking?
Thinking concurrently allows multiple tasks to be processed simultaneously, leading to improved performance and responsiveness of programs. It can also improve fault tolerance and help avoid issues such as deadlocks and race conditions.
What is a function and how is it used in programming?
A function is a named block of code that returns a value. In programming, functions can be used to encapsulate complex logic or calculations, and can be reused throughout a program.
What is the merge sort algorithm, and how does it work?
The merge sort algorithm is a sorting algorithm used to sort a list or array of values. It works by dividing the list into smaller sublists, sorting the sublists recursively, and then merging the sorted sublists back together.
What is the purpose of the "head" node in a linked list?
The head node in a linked list represents the first node in the list and serves as the starting point for traversing the list.
What is a two-dimensional array?
An array with two indices or dimensions, used to store data in rows and columns.
How can thinking procedurally be used in problem solving?
It is a critical aspect of problem solving as it allows us to take a systematic approach to developing solutions.
What is an object?
An object is a collection of data and methods that represent a real-world entity or concept.
What is Big O notation used for in algorithm analysis and comparison?
Big O notation is used to describe the upper bound of the time or space complexity of an algorithm, allowing for comparison of different algorithms based on their efficiency.
Which logic gate is represented by the symbol "⊕" and what is its truth table?
The XOR gate, which outputs 1 only when one input is 1 and the other is 0, has the truth table: 0 ⊕ 0 = 0, 0 ⊕ 1 = 1, 1 ⊕ 0 = 1, and 1 ⊕ 1 = 0.
What is a linker, and what is its role in the compilation process?
A linker is a program that combines multiple object files and resolves references between them to produce an executable file.
What are the benefits of caching in problem solving and programming?
Caching can improve program performance by storing frequently used data in a cache, which can be accessed more quickly than data stored in other memory locations. This can reduce the amount of time required to retrieve and process data, and improve overall program efficiency.
What are 4 uses of data mining in the field of computer science?
Data mining can be used to analyse large datasets and extract useful insights and patterns. It is commonly used in areas such as marketing, finance, and healthcare to identify trends, make predictions, and support decision-making.
What is Dijkstra's shortest path algorithm, and how does it work?
Dijkstra's shortest path algorithm is a popular algorithm used to find the shortest path between two nodes in a graph with non-negative edge weights. The algorithm works by maintaining a priority queue of nodes, with the node with the smallest tentative distance from the start node at the front of the queue. The algorithm then iteratively visits the neighbors of the node at the front of the queue, updating their tentative distances and adding them to the priority queue if necessary. This process continues until the algorithm has visited all reachable nodes or the destination node is found.
What is the purpose of a cache memory in a computer system?
A cache memory is a small, fast memory that stores frequently accessed data or instructions to reduce the time needed to access them from the main memory.
Describe post order tree traversal in depth-first search?
Post order traversal visits the left and right subtrees first, and then the root node.