-
The isFull() member method is called within the enqueue process to determine ?
Skill/Topic: QueueA) if there is room to place another item in the queue.B) if there is an item in the queue to be removedC) if there is an item in the queue to be locked
-
What is a queue ?
Skill/Topic: QueueA) A Queue is a sequential organization of data.
-
What is the purpose of the isEmpty() member method?
Skill/Topic: Stacks using an ArrayA) The isEmpty() member method determines if a value is at the top of the stack and is called before an attempt is made to remove the value
-
Popping removes an item from the stack.
Skill/Topic: Stacks using an ArrayA) TrueB) FalseExplanation: Popping is the reverse process of pushing: it removes an item from the stack. It is important to understand that popping an item off the stack doesn’t copy the item. Once an item is popped from the stack, the item is no longer available on the stack, although the value remains in the array
-
_________ method places a value onto the top of a stack.
Skill/Topic: Stacks using an ArrayA) push() member methodB) pop() member methodC) isFull() member methodD) isEmpty() member methodExplanation: Push is the direction that data is being added to the stack. push() member method places a value onto the top of a stack.
-
Allocating memory at runtime is also called as?
Skill/Topic: ArrayA) Statically allocating memoryB) Dynamically allocating memoryC) Sequentially allocating memoryD) All of the aboveExplanation: Allocating memory at runtime is called a dynamically allocating memory. In this,you dynamically allocate memory by using the new operator when declaring the array, for example:int grades[] = new int[10];
-
The symbol * is also called as _________________.
Skill/Topic: Variables and PointersA) pointer dereferencing operatorExplanation: (sometimes called as dereferencing operator)
-
Pointer to a pointer is used in a program to ?
Skill/Topic: Variables and PointersA) arrange data by moving data in memoryB) arrange data by moving pointer in memoryC) arrange data without having to move data in memory.D) None of the aboveExplanation: Pointer to a pointer is used in a program to arrange data without having to move data in memory.
-
Why is the binary numbering system used in computing?
Skill/Topic: Memory, Abstract Data Types, and AddressesA) The binary numbering system is used in computing because it contains 2 digits that can be stored by changing the state of a transistor. Off represents 0 and On represents 1.
-
The size of a structure is determines by the Product of sizes of all primitive data types within the structure?
Skill/Topic: Variables and PointersA) TrueB) FalseExplanation: The size of a structure is the sum of the sizes of all the primitive data types within the structure
-
-
A pointer to a pointer is a variable whose value is an ________ of another _______ variable.
Skill/Topic: Variables and PointersA) Address, PointerExplanation: A pointer to a pointer is a variable whose value is an address of another pointer variable
-
The destroyList() member function deletes the contents of the linked list and ________________.
Skill/Topic: Linked ListA) does not delete the linked list itselfB) delete the linked list itselfC) adds the linked list itselfD) None of the aboveExplanation: The destructor is a member function called when the instance of the LinkedList class is deleted using the delete operator. In the example shown next, the destructor contains one statement that calls the destroyList() member function.The destroyList()...
-
_____ is the common programming technique used for hashing in all hashing functions.
Skill/Topic: Hash TableA) Bit Shifting
-
-
Why would you use a structure?
Skill/Topic: Variables and PointersA) You use a structure to access parts of a dataB) You use a structure to group together related data.C) You use a structure to declare an instance of data groupExplanation: Structure is used to group all related data together
-
Node on a queue linked list have more than one data element.
Skill/Topic: Queues Using Linked ListsA) TrueB) False
-
Why is the constructor of the QueueLinkedList class empty?
Skill/Topic: Queues Using Linked ListsA) because initialization of data members of the LinkedList class is performed by the constructor of the LinkedList class.B) because initialization of data members of the LinkedList class is performed by the destructor of the LinkedList class.C) because initialization of data members of the QueueLinkedList class is performed by the constructor of the LinkedList...
-
119 Let’s say that you need to access a particular node on a linked list, but you don’t know the reference to the node or the position the node has on the linked list, although you do know the data is stored in the node. You can locate the node by calling the _____ function.
Skill/Topic: Stacks and Queues: Insert, Delete, Peek, FindA) insertNode()B) giveNode()C) findNode()D) cannot locate the node at all
-
Astack is a data structure that organizes data similar to how you organize dishes in a stack on your kitchen counter.
Skill/Topic: Stacks using Linked ListA) TrueB) False
Data Structures Interview Questions
Ans