Posts

Showing posts from October, 2021

Data Structure MCQ (Multiple Choice Questions) || 20 MCQ QUESTIONS

Image
Question 1: Consider the following singly linked list wherein each node of the linked list contains a data (integer) and a link pointing to the next node: What would be the outputs of the following if the initial call is func(head): void func(node* root) { if(!root)      return;  printf("%d, ",root->data); func(root->link); } Select one: a. 20, 5, 15, 10 b. 20 c. None of these d. 10, 15, 5, 20 The correct answer is: 10, 15, 5, 20 Question 2: How many maximum pointers will get updated in removal of a term from a polynomial stored in a doubly circular linked list? a. 3 b. 2 c. 4 d. 1 The correct answer is: 2 Question 3:  How many minimum pointers will get updated in removal of a term from a polynomial stored in a doubly linked list? a. 3 b. 4 c. 1 d. 2 The correct answer is: 1 Question 4 Consider the following keys to be stored in a hash table of size 13 (location 0 to location 12) using division method and linear probing is used as the collision resolution ...

Computer System Organization MCQ (Multiple Choice Questions) || 20 MCQ QUESTION

 Question 1: Assembly language a. uses alphabetic codes in place of binary numbers used in machine language b. need not be translated into machine language c. None of these d. is the easiest language to write programs The correct answer is: uses alphabetic codes in place of binary numbers used in machine language Question 2: Which basic components are used in second generations computers? a. Integrated Circuit b. Transistor c. Vacuum tubes d. Gates The correct answer is: Transistor Question 3: Which of the following is not the instruction code formats of basic computer a. The register reference instructions b. A memory-reference instructions c. The operation code d. Control reference instructions The correct answer is: Control reference instructions Question 4: (2FAOC) 16 is equivalent to a. Both b. (001011111010 0000 1100)2 c. None of these d. (195 084)10 The correct answer is: (001011111010 0000 1100)2 Question 5: In Binary coded decimal format each decimal unit is encoded by a. ...

Q1. Method to convert sparse matrix to linked list in c ......................... ?

  /**  * Lab assignment 1  * CSL 210   * Deadline: Saturday September 4 by 6am.  * Submit the c implementation file for this header file  * Filename should be of format YourEnrollmentNumber_lab1.c (lower case); e.g., bt20cse999.c  *   * Implement all the functions even if the solution is imperfect. If you dont implement all functions,  * it will result in a compilation error  *  *   * Compilation error = 0  * Late submission = 0  * Presence of uncommented main function in the submission file = 0  * Cheating/plagiarism = 0  * */ #define EMPTYNODE 0 #define SIZE_HASH_TABLE 5 struct nodeQ{     unsigned short row;     unsigned short column;     short value;     struct nodeQ* next; }; typedef struct nodeQ nodeQ_t; struct priorityNodeQ{     unsigned short value;     unsigned short priority;     struct priorityNodeQ* next; }; typed...