Search
Question: Which of the following statements is true about the Bellman-Ford algorithm?Options: It can..
Question: Which of the following is an example of a problem that can be solved using divide and conq..
Question: What happens if a recursive function does not have a base case?Options: It will run indefi..
Question: Which of the following is true about recursive algorithms?Options: They always run faster ..
Question: What is tail recursion?Options: Recursion where the last operation is a recursive callRecu..
Question: Which of the following problems can be solved using recursion?Options: Finding the maximum..
Question: In a recursive function, what is the purpose of the return statement?Options: To terminate..
Question: Which of the following is a base case in a recursive function?Options: The case that leads..
Question: What is the time complexity of a recursive function that divides the problem size by half ..
Question: What does the term \'memory leak\' refer to?Options: Not freeing allocated memoryAccessing..
Question: What is the size of a pointer on a 64-bit system?Options: 2 bytes4 bytes8 bytes16 bytesCor..
Question: What is a dangling pointer?Options: A pointer that points to a valid memory locationA poin..
Question: Which of the following is true about pointers?Options: Pointers can only point to integers..
Question: What is the purpose of the \'free\' function in C?Options: To allocate memoryTo release al..
Question: What is the result of dereferencing a null pointer?Options: It returns zeroIt causes a seg..
Question: What does the \'malloc\' function do in C?Options: Allocates memory on the stackAllocates ..
Question: Which operator is used to access the value at the address stored in a pointer?Options: &*-..
Question: What is a pointer in programming?Options: A variable that stores a memory addressA type of..
Question: What is the key difference between greedy algorithms and dynamic programming?Options: Gree..
Question: Which of the following is a common application of greedy algorithms?Options: Sorting dataF..
Question: What is the main drawback of greedy algorithms?Options: They are too slowThey may not prod..
Question: In the coin change problem, which approach does a greedy algorithm use?Options: Always tak..
Question: Which greedy algorithm is used to solve the activity selection problem?Options: Dijkstra\'..
Question: What is the time complexity of Prim\'s algorithm for finding the minimum spanning tree usi..
Question: Which of the following is NOT a characteristic of greedy algorithms?Options: They make dec..
Question: In the context of greedy algorithms, what does \'local optimum\' refer to?Options: The bes..
Question: Which of the following problems can be solved using a greedy algorithm?Options: Knapsack p..
Question: What is a greedy algorithm?Options: An algorithm that makes the best choice at each stepAn..
Question: Which of the following statements is true about BFS?Options: BFS can be implemented using ..
Question: What is a key characteristic of DFS compared to BFS?Options: DFS uses less memory than BFS..