logo

Crowdly

Data Structures and Algorithms

Looking for Data Structures and Algorithms test answers and solutions? Browse our comprehensive collection of verified answers for Data Structures and Algorithms at moodle.lnmiit.ac.in.

Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!

Consider a stack is implemented using array A of size N. The pseudocode for Push() and Pop() operations are given below, where the top points to the top element of the stack.

 

 Condition for stack empty is:

View this question

Consider a singly circular linked list with a maintaining Tail pointer; follow these steps as given below:

1. Create a node: NewNode

2. NewNode -> next = Tail -> next

3. Tail -> next = NewNode

4. Tail = NewNode

Using the above steps, predict what will be the correct operation with time complexity:

View this question

What is the output of the following program?

struct node

{

int data;

struct node *next;

};

 

main()

{

struct node N1, N2, N3;

N1.data = 1; N2.data = 10; N3.data = 100;

N1.next = &N2; N2.next = &N3; N3.next = &N1;

printf("%d, %d", N2.next -> data, N2.next -> next -> data);

}

View this question

What are the postfix equivalents of the given infix expressions:  A*(B+D)/E –F *(G + H/K)

View this question

Which of the following permutations can be obtained in the same order using stack, assuming that the input sequence is given as E, F, G, H, I:

View this question

push(24), push(22), a=pop(), push(25), push(32), pop( ), b=pop().

Here, push() and pop() represent the push and pop operation of the stack, and ‘a’, and ‘b’ are two variables.

What will be the value of |a – b|?

View this question

Consider the following postfix expression: 5, 6, 2, +, *, 12, 4, /, –.   

What is the evaluated output of the above expression using stack?

View this question

Want instant access to all verified answers on moodle.lnmiit.ac.in?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!