Exercises Videos Notes Multiple-choice questions

Related books

Introduction to Theory of Computation Theory of Computation Computational Complexity: A Modern Approach The Art of Mathematics: Coffee Time in Memphis Mathematical Mind-Benders Combinatorial Problems and Exercises Computational Complexity Computers and Intractability: A Guide to the Theory of NP-Completeness Algorithmic Puzzles Mathematical Puzzles: A Connoisseur's Collection Suggest a Book
2

Read Once Promised Majority

Level: unknown
 

posted Jun 06 '12

domotorp gravatar image domotorp flag of Hungary
41 1 5
http://www.cs.elte.hu/~do...

Suppose the input is $n$ numbers from $1$ to $n$, separated by commas and we know that one of the number occurs more than $n/2$ times. How can we decide which if we can read the input tape only once (from left to right) and we also have a work tape of size $O(\log n)$?

Example input: 11,101,11,110,101,101,101

Printable version LaTeX source
delete flag offensive retag edit

Stats

Posted: Jun 06 '12

Seen: 134 times

Last updated: Aug 04 '12