Reflowed problems and added solutions
This commit is contained in:
@@ -1,21 +1,14 @@
|
||||
Advent of Code
|
||||
|
||||
br0xen 40*
|
||||
|
||||
• [About]
|
||||
• [Stats]
|
||||
• [Leaderboard]
|
||||
• [Settings]
|
||||
• [Log out]
|
||||
Advent of Code
|
||||
|
||||
--- Day 9: All in a Single Night ---
|
||||
|
||||
Every year, Santa manages to deliver all of his presents in a single night.
|
||||
|
||||
This year, however, he has some new locations to visit; his elves have provided him the
|
||||
distances between every pair of locations. He can start and end at any two (different)
|
||||
locations he wants, but he must visit each location exactly once. What is the shortest distance
|
||||
he can travel to achieve this?
|
||||
This year, however, he has some new locations to visit; his elves have
|
||||
provided him the distances between every pair of locations. He can start and
|
||||
end at any two (different) locations he wants, but he must visit each
|
||||
location exactly once. What is the shortest distance he can travel to
|
||||
achieve this?
|
||||
|
||||
For example, given the following distances:
|
||||
|
||||
@@ -32,8 +25,8 @@
|
||||
Belfast -> Dublin -> London = 605
|
||||
Belfast -> London -> Dublin = 982
|
||||
|
||||
The shortest of these is London -> Dublin -> Belfast = 605, and so the answer is 605 in this
|
||||
example.
|
||||
The shortest of these is London -> Dublin -> Belfast = 605, and so the
|
||||
answer is 605 in this example.
|
||||
|
||||
What is the distance of the shortest route?
|
||||
|
||||
@@ -41,14 +34,14 @@
|
||||
|
||||
--- Part Two ---
|
||||
|
||||
The next year, just to show off, Santa decides to take the route with the longest distance
|
||||
instead.
|
||||
The next year, just to show off, Santa decides to take the route with the
|
||||
longest distance instead.
|
||||
|
||||
He can still start and end at any two (different) locations he wants, and he still must visit
|
||||
each location exactly once.
|
||||
He can still start and end at any two (different) locations he wants, and he
|
||||
still must visit each location exactly once.
|
||||
|
||||
For example, given the distances above, the longest route would be 982 via (for example) Dublin
|
||||
-> London -> Belfast.
|
||||
For example, given the distances above, the longest route would be 982 via
|
||||
(for example) Dublin -> London -> Belfast.
|
||||
|
||||
What is the distance of the longest route?
|
||||
|
||||
@@ -56,12 +49,11 @@
|
||||
|
||||
Both parts of this puzzle are complete! They provide two gold stars: **
|
||||
|
||||
At this point, you should return to your advent calendar and try another puzzle.
|
||||
At this point, you should return to your advent calendar and try another
|
||||
puzzle.
|
||||
|
||||
If you still want to see it, you can get your puzzle input.
|
||||
|
||||
You can also [Shareon Twitter Google+ Reddit] this puzzle.
|
||||
|
||||
References
|
||||
|
||||
Visible links
|
||||
@@ -73,6 +65,3 @@ References
|
||||
. http://adventofcode.com/auth/logout
|
||||
. http://adventofcode.com/
|
||||
. http://adventofcode.com/day/9/input
|
||||
. https://twitter.com/intent/tweet?text=I%27ve+completed+%22All+in+a+Single+Night%22+%2D+Day+9+%2D+Advent+of+Code&url=http%3A%2F%2Fadventofcode%2Ecom%2Fday%2F9&related=ericwastl&hashtags=AdventOfCode
|
||||
. https://plus.google.com/share?url=http%3A%2F%2Fadventofcode%2Ecom%2Fday%2F9
|
||||
. http://www.reddit.com/submit?url=http%3A%2F%2Fadventofcode%2Ecom%2Fday%2F9&title=I%27ve+completed+%22All+in+a+Single+Night%22+%2D+Day+9+%2D+Advent+of+Code
|
||||
|
Reference in New Issue
Block a user