# All Questions

44,851 questions
Filter by
Sorted by
Tagged with
1 vote
48 views

118 views

### Is there a working O(1)-space flood fill algorithm?

This is a purely theoretical question: among the known flood fill algorithms, there is one which does not require any dynamically-sized data structures, explicit or implicit: the so-called Walk-based ...
9 views

### Checking for equality before calculating product of a matrix with inverse of another matrix

I have an operation that is performed many times and is thus performance sensitive where I need to calculate product of a matrix and inverse of a matrix as below. Both matrices are 4x4 and consist of ...
1 vote
22 views

18 views

### how to achieve the maximum height in red black trees?

As we know, the maximum height of a red black tree is 2* log (n+1). So lets say we have six nodes [1,2,3,4,5,6]. How to insert them to achieve the maximum height ?
50 views

### If A is reducible to B, assuming A is hard, why can't "B is easy" update our belief to A is easy?

The concept of reducibility in computability theory is very confusing for me. For example, as described in Micheal Sipser's Introduction to the theory of computation, I understand that if language A ...
85 views

### Do Knuth-Morris-Pratt and Booth’s LCS algorithm work in linear time on lists of strings? [migrated]

As a subroutine for an algorithm we’re working on, we need to compute the lexicographically minimal rotation (or least circular shift) of a list of strings. The problem is well-known and several ...
1 vote