Skip to content

Tag Archives: Misc

#include <stdio.h> int main() {     int a[][3] = {1, 2, 3, 4, 5, 6};     int (*ptr)[3] = a;     printf("%d %d ", (*ptr)[1], (*ptr)[2]);     ++ptr;     printf("%d… Read More
What is the return value of following function for 484? What does it to in general? bool fun(int n) {     int sum = 0;     for… Read More
Assume that the size of an integer is 4 bytes. Predict the output? #include <stdio.h> int fun() {     puts(" Hello ");     return 10; }   … Read More
You are given an array with even integer elements. You and some other player take turns to pick numbers. Each player can pick either the… Read More
Which of the following data structures is best suited for efficient implementation of priority queue? (A) Array (B) Linked List (C) Heap (D) Stack Answer:… Read More
Consider a situation where a client receives packets from a server. There may be differences in speed of the client and the server. Which data… Read More
Which data structure is best suited for converting recursive implementation to iterative implementation of an algorithm? (A) Queue (B) Stack (C) Tree (D) Graph Answer:… Read More
Which of the following is the best possible time complexity to get Nth Fibonacci number with O(1) extra space (A) Time complexity T(n) is T(n-1)… Read More
There are 25 horses among which you need to find out the fastest 3 horses. You can conduct race among at most 5 to find… Read More
Which among the following data structures is best suited for storing very large numbers (numbers that cannot be stored in long long int). Following are… Read More
Which of the following best describes C language (A) C is a low level language (B) C is a high level language with features that… Read More
In the above question, if array A is made to hold the string “abcde”, which of the above four test cases will be successful in… Read More
The procedure given below is required to find and replace certain characters inside an input character string supplied in array A. The characters to be… Read More
An inversion in a an array A[] is a pair (A[i], A[j]) such that A[i] > A[j] and i < j. An array will have… Read More
The most appropriate matching for the following pairs X: depth first search 1: heap Y: breadth-first search 2: queue Z: sorting 3: stack is (GATE… Read More

Start Your Coding Journey Now!