Penguin Tournament Strategy and Solutions

hkoi senior q2 igloo n.w
1 / 12
Embed
Share

Discover the strategic approach to a penguin tournament where cute penguins face off against monsters. Learn how to determine the winner in different scenarios and explore alternative solutions for success. Dive into the full solution guide and unravel the secrets to mastering the competition.

  • Penguin
  • Tournament
  • Strategy
  • Solutions
  • Competition

Uploaded on | 0 Views


Download Presentation

Please find below an Image/Link to download the presentation.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author. If you encounter any issues during the download, it is possible that the publisher has removed the file from their server.

You are allowed to download the files provided on this website for personal or commercial use, subject to the condition that they are used lawfully. All files are the property of their respective owners.

The content on the website is provided AS IS for your information and personal use only. It may not be sold, licensed, or shared on other websites without obtaining consent from the author.

E N D

Presentation Transcript


  1. HKOI Senior Q2 - Igloo Ivan Li

  2. Background A peaceful sports event of innocent cute little penguins...... mercilessly destroyed by Big Bad Monsters!

  3. In short Single elimination tournament Tree structure Taller penguin wins In case of a tie, compare index Must not let monsters win!

  4. Direct simulation Stores the penguins in an array, and simulate the competition process After some tedious typing work, you get 50%

  5. When there is no monsters The tallest penguin wins If tie, the lowest index Hurrah! 20%!

  6. When monsters step in They may beat the potential winners Good news monsters live in the same igloo. Their indexes are consecutive

  7. Observation 1 When the monsters are not the tallest, we don t have to be afraid of them Just ignore them

  8. Observation 2 When the monsters on the left subtree, all normal penguins in that subtree will be beaten. Only consider the right subtree Similar holds for right subtree

  9. Full Solution Call the penguins on the left(right) of the monsters the left(right) band . Find the largest subtree that is included in the bands Lengths must be power of 2 Which subtree survives longer? The taller (larger) one Tie the right one The tallest penguin in that subtree

  10. Full Solution

  11. Alternative solution Maintain the start and end index of each igloo Simulate the rounds Calculate the boundaries Match on the boundaries? Who wins?

  12. Questions?

More Related Content