Question Detail: In our computer systems lecture we were introduced to the MIPS processor. It was (re)developed over the course of the term and has in fact been quite easy to understand. It uses a RISC design, that is its elementary Read More …
Category: Uncategorized
Proof that a randomly built binary search tree has logarithmic height
Question Detail: How do you prove that the expected height of a randomly built binary search tree with $n$ nodes is $O(log n)$? There is a proof in CLRS Introduction to Algorithms (chapter 12.4), but I don’t understand it. Asked By Read More …
Proof that a randomly built binary search tree has logarithmic height
Question Detail: How do you prove that the expected height of a randomly built binary search tree with $n$ nodes is $O(log n)$? There is a proof in CLRS Introduction to Algorithms (chapter 12.4), but I don’t understand it. Asked By Read More …
Why would anyone want CISC?
Question Detail: In our computer systems lecture we were introduced to the MIPS processor. It was (re)developed over the course of the term and has in fact been quite easy to understand. It uses a RISC design, that is its elementary Read More …
Where are back edges in a DFS tree?
Question Detail: As I understand it when doing a DFS run when every new node is discovered and edge is added to the DFS tree from the parent of the new node to the new node. If that’s the case how Read More …
Language theoretic comparison of LL and LR grammars
Question Detail: People often say that LR(k) parsers are more powerful than LL(k) parsers. These statements are vague most of the time; in particular, should we compare the classes for a fixed $k$ or the union over all $k$? So how Read More …
How to map the tapes of a “k-tape” Turing Machine into the single tape of a “1-tape” Turing Machine
Question Detail: I’m reading Sipser and I’m finding it hard to understand what the process is such that if you give me k Turing machines with k tapes, I can spit out an equivalent Turing machine with only one tape. An Read More …
How hard is counting the number of simple paths between two nodes in a directed graph?
Question Detail: There is an easy polynomial algorithm to decide whether there is a path between two nodes in a directed graph (just do a routine graph traversal with, say, depth-first-search). However it seems that, surprisingly, the problem gets much harder Read More …
Generalised 3SUM (k-SUM) problem?
Question Detail: The 3SUM problem tries to identify 3 integers $a,b,c$ from a set $S$ of size $n$ such that $a + b + c = 0$. It is conjectured that there is not better solution than quadratic, i.e. $mathcal{o}(n^2)$. Or Read More …
Are there NP problems, not in P and not NP Complete?
Question Detail: Are there any known problems in $mathsf{NP}$ (and not in $mathsf{P}$) that aren’t $mathsf{NP}$ Complete? My understanding is that there are no currently known problems where this is the case, but it hasn’t been ruled out as a possibility. Read More …