Coding Games and Programming Challenges to Code Better
Send your feedback or ask for help here!
Created by @nguyen.lam,validated by @Regulus136,@Timinator and @ANONYMOUS42.
If you have any issues, feel free to ping them.
Coding Games and Programming Challenges to Code Better
Send your feedback or ask for help here!
Created by @nguyen.lam,validated by @Regulus136,@Timinator and @ANONYMOUS42.
If you have any issues, feel free to ping them.
If an Elf is to complete this map:
5
5
#####
>...#
#...#
##..>
#####
would the path be:
#####
>...#
#o..#
##o>>
#####
I see you have solved the puzzle so you probably already know the answer but in the statement it says about the elf:
When both give same result, prioritize straight moves as opposed to diagonal moves.
So the correct path should be:
#####
>>o.#
#…o#
##…>
#####
Hi,
I’m in trouble to understand the path in the solution of the test 8:
If I take the possibility to turn while destroying the wall, I find this solution :
####################
#....#..#...#...##.#
#.##......#...#...##
#..##############..#
#.#.###.##########.#
#.....#######...##.#
#####.#.#.#.###.#..#
<<....######.#.#..##
#^#############.#..#
#^<##############..#
##^..##...##......##
##^#....#....#######
#>^#################
#^.###############.#
#^##.........##.#.##
#^##.#.#.###.##..#.#
#^##.###.###.##..#.#
#^<v<<<<<<<<<<#.#.##
#.^<.####.##.^...#.#
#############^######
and then the result on test 4 is :
###########
#....#....#
#...#.#...#
#..#####..#
#..#####..#
#.###.###.#
>>v##.##>>>
#.>>>>>>^.#
#...###...#
#..#...#..#
#..#...#..#
#....#....#
###########
now if I consider the turn not possible, test 4 is then ok and the test 8 is then :
####################
#....#..#...#...##.#
#.##...v<<<<<<<<<<##
#..####v#########^<#
#.#.###v##########^#
#.v<<<#v#####...##^#
##v##^<<#.#.###>>>^#
<<<...######.#.^..##
###############^#..#
#.#############^#..#
##...##...##>>>^..##
##>>>>>>>>>>^#######
##^#################
#>^###############.#
#^##.........##.#.##
#^##.#.#.###.##..#.#
#^##.###.###.##..#.#
#^##v<<<<<<<<##.#.##
#^<<<####.##^<...#.#
#############^######
On top of this the part of the solution path (r7 c13) (r6 c13) and (r6 c12) is very strange to me as it means to destroy the wall 3 times, at first read it seems not aligned with “The DWARF can break walls if the wall thickness is only 1 cell.”
To me this part of the puzzle is far from beeing clear.
The way I implemented “wall thickness is only 1 cell” is that, once a direction is chosen, I look two squares ahead, and if the immediately next one is a “#” and the next one a “.”, then I can break it and move to the “#”.
So in your first example, this is illegal to me:
#^##.#
#^<v<<
#.^<.#
######
(From the original maze of:
#.##.#
#.##.#
#....#
######
)
I allow myself to “turn” (as in to explore the 4 directions allowed to the DWARF), at each turn, including after just destroying a wall.
Yes after a first implementation and a second as explained in my earlier message, I figured out the real puzzle request but I think it would be worth to clarify this point for next players.
rgds
Does anyone have any hints for “6: Complex for Elf Validator”? At first I thought it might be an issue with prioritizing straight movements but I’ve made some additional test cases and my code seems to be prioritizing straight movements properly.
It’s difficult to give hints for this puzzle. If you want, you may send me your code in private message and I’ll take a look to see what hints may be given.