ExamVeda
Login
Home
91
What is the functionality of the following piece of code?
public void function(Object item)
{
	Node temp=new Node(item,trail);
	if(isEmpty())
	{
		head.setNext(temp);
		temp.setNext(trail);
	}
	else
	{
		Node cur=head.getNext();
		while(cur.getNext()!=trail)
		{
			cur=cur.getNext();
		}
		cur.setNext(temp);
	}
	size++;
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
92
What is the time complexity to insert a node based on position in a priority queue?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
93
In general, the index of the first element in an array is . . . . . . . .
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
94
The postfix form of A*B+C/D is?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
95
Consider the following doubly linked list: head-1-2-3-4-5-tail. What will be the list after performing the given sequence of operations?
Node temp = new Node(6,head,head.getNext());
Node temp1 = new Node(0,tail.getPrev(),tail);
head.setNext(temp);
temp.getNext().setPrev(temp);
tail.setPrev(temp1);
temp1.getPrev().setNext(temp1);
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
96
Which of the following is not the application of stack?
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
97
Which of the following is true about linked list implementation of queue?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
98
What is the time complexity of pop() operation when the stack is implemented using an array?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
99
What is the time complexity of deleting from the rear end of the dequeue implemented with a singly linked list?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
100
The data structure required for Breadth First Traversal on a graph is?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board