New answers tagged

1 vote

Delete consecutive characters and add zeros at the end with a restriction

Have a write index. Then go through the array, identify and measure each streak of equal characters. Streaks shorter than 3 get written. At the end, write zeros at the remaining indices. Python ...
user avatar
1 vote

Delete consecutive characters and add zeros at the end with a restriction

While waiting for your updated post that includes your solution, I have posted mine: Solution A substring is deletable if all its characters will be deleted based on your requirement. This substring ...
user avatar
  • 1,257
2 votes
Accepted

Difficulty understanding the CANYIELD function in the Sipser text's proof of Savitch’s theorem

You can enumerate every possible configuration $c_m$ of $N$, this process takes only $O(f(n))$ space First, lets consider the number of configuration of $N$ that runs in $f(n)$ space If $N$ runs in $f(...
user avatar
  • 609
1 vote
Accepted

Implications of Savitch's theorem

For the first two, we do not know whether it is true or false. It is not known whether $\text{NSpace}(\log n)$ = $\text{DSpace}(\log n)$, although Savitch’s theorem implies that $\text{NSpace}(\log n)...
user avatar
  • 33k

Top 50 recent answers are included