Recent questions tagged goclasses-cs-dpp-day-314

4 4 votes
3 3 answers
236
236 views
Which state in the following DFA should be made the initial state to make it accept the language $L = \{w \in \{0,1\}^* \mid w$ has even number of $1$s and odd number of ...
4 4 votes
3 3 answers
218
218 views
Which of the following is the correct description of language recognized by the DFA below?Binary strings not divisible by $4$ Binary strings divisible by $4$ Binary strin...
3 3 votes
3 3 answers
203
203 views
The node $q_2$ is best defined as $\dots$ $\dots$Final state Dead state Both final and dead state Neither final nor dead state
5 5 votes
4 4 answers
222
222 views
Which of the following states would be notated as the final state/acceptance state for $L = \{x \in \Sigma^* : \text{length of } x \text{ is } 2\},\ \Sigma = \{a,b\}$?$q...
3 3 votes
3 3 answers
251
251 views
3 3 votes
3 3 answers
220
220 views
Consider the following singly linked list:$\texttt{'B' - 'A' - 'S' - 'E' - NULL}$The pointer $\texttt{head}$ points to the first node containing $\texttt{'B'}$.What chara...
6 6 votes
2 2 answers
223
223 views
A singly linked list maintains two pointers:struct Node *front; // points to first node struct Node *rear; // points to last nodeWhich operation would be inefficient when...
9 9 votes
2 2 answers
238
238 views
Consider the problem of finding the middle node in a list $l$ of size $n$, given that $n$ is odd. Count the number of accesses to positions of list $l$ needed to find the...
7 7 votes
4 4 answers
231
231 views
Consider the following C function intended to delete the last node of a singly linked list:void removeLast(struct Node *head) { struct Node *p = head; struct Node *q = p-...
6 6 votes
3 3 answers
230
230 views
Consider the following structure:struct Node { int data; struct Node *next; };A function should insert a new node containing value $\texttt{x}$ at the beginning of a sing...
To see more, click for the full list of questions or popular tags.