Skip to content

eric-bunch/Line-up-rabbits

Repository files navigation

Line-up-rabbits

I remembered to copy the word problem, so for the setup refer to the file line_up_the_captives.txt

I did not finish this one in time, but was able to come up with code that correctly counts the number of ways to line up the rabbits later in the day after the deadline passed. I'm very sure that it's correct because I wrote a code snippet (the commented part at the bottom of line_up_the_captives.py) that computed the number of ways to line up the rabbits, but in an extremely inefficient way. Then I had some lines of code that checked the two methods against each other for fairly small numbers. Even though the numbers were small, there were still a good number of cases, and I think the numbers were big enough to see any strange behaviour that might have occured.

Although I'm very confident the code I have written computes the correct thing, it still runs too slowly on some larger numbers. But it is still a pretty early version of the code. I still need to go through and refactor it to speed some things up.

About

foobar challenge lv4

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages