VibraXX
Live Quiz Arena
🎁 1 Free Round Daily
⚡ Enter Arena
HomeCategoriesLogic & PuzzlesQuestion
Question
Logic & Puzzles

A Las Vegas algorithm searches a linked list. If re-sampling a random node takes too long, what occurs?

A)Deterministic execution time increases
B)Memory usage becomes unpredictable
C)Correctness of output is compromised
D)Runtime varies, correctness is assured

💡 Explanation

A Las Vegas algorithm guarantees a correct result but its runtime is probabilistic; therefore, prolonged resampling increases runtime, because the algorithm continues until it finds the solution. Correctness isn't sacrificed, rather than an incorrect solution being returned.

🏆 Up to £1,000 monthly prize pool

Ready for the live challenge? Join the next global round now.
*Terms apply. Skill-based competition.

⚡ Enter Arena

Related Questions

Browse Logic & Puzzles