Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Weekly Challenges

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語
IDEAS WANTED

Want to get involved? We're always looking for ideas and content for Weekly Challenges.

SUBMIT YOUR IDEA

Challenge #123: When will Rabbits Rule the World?

JoeM
Alteryx Alumni (Retired)

This one has been on my whiteboard for awhile and I've been meaning to publish this challenge. This weekly challenge should be a fun one! The question we are trying to answer is: In what future month/year will a new breed of rabbits to exceed the human population 2:1?

rabbits.gif

 

Let's set some rules for how this new breed of rabbit populates so we can try to find the day our civilization will be be under the rule of our new-found long-eared overlords.

1) We will start with 1 female and 1 male rabbit born today (0 months old)
2) Each month, each female produces a litter of 4 bunnies: 1 male and 3 females
3) A female cannot start to reproduce until she has matured to 4 months of age
4) All rabbits live only to 24 months in age. (Alive months 0-23, they cease to live at the start of the 24th month)

5) Don't forget human population grows too! Assume a 0.058% month over month human population growth!

 

I have provided an answer, but there may be little monthly nuances that account for slightly different answers. Sound-off on when you found out it is going to happen!

 

 

patrick_digan
17 - Castor
17 - Castor
Spoiler
I went for an iterative macro. It only took 41 iterations.
Workflow:
Capture.PNG

Macro:
Capture2.PNG
TerryT
Alteryx Alumni (Retired)

I got the same month, but my numbers don't match exactly!

 

Spoiler
challenge_123_TTT.PNG
CharlieS
17 - Castor
17 - Castor

I got the same date, but slightly different population counts for humans and the Supreme Overlords. Maybe this is close enough to count like in horseshoes and Holy Hand Grenades.

 

Spoiler
785,514,304 long-eared overlords and 336,183,913 humans

MontyPythonRabbit.png
NicoleJohnson
ACE Emeritus
ACE Emeritus

RabbitFunny.jpg

 

Slightly different human population for my final result, with 24 extra humans - which frankly, in this terrifying scenario, I will gladly take. 

 

Spoiler
WeeklyChallenge123.JPGWeeklyChallenge123Macro.JPG

Thanks for the super fun challenge, @JoeM! I can see why you were so excited for this one :) Now, off to go pull anything that looks like a carrot out of my garden, just in case...

 

Cheers,

NJ

terry10
12 - Quasar

Averting my eyes from the GIF, I didn't notice the 2:1 population threshold and spent way too much time trying to find the error in my workflow.  :(  

 

Spoiler
123_terry10.JPG
mmongeon
8 - Asteroid

Here's my solution.

Like many of the other submissions, I don't have the exact same population numbers, but I end up on the same month.

Spoiler
Main workflow:
Capture 123 main.JPG
Iterative macro:
Capture 123 macro.JPG

 

patrick_digan
17 - Castor
17 - Castor

@mmongeon Your solution truly made my day! 51 formulas in one formula tool! 

Ladarthure
14 - Magnetar
14 - Magnetar

Was very funny and made me learn how to use the iterative macro, thank's to @patrick_digan for the first answer and showing a way to do this macro (was planning to use multi_rows formula...

ggruccio
ACE Emeritus
ACE Emeritus

Going to see iterations of rabbits in my sleep!