PHP находит кратчайший путь в двумерном массиве, напоминающем лабиринт ⇐ Php
PHP находит кратчайший путь в двумерном массиве, напоминающем лабиринт
I am working on a 2D string with \n new line at the end.
The maze is 1000 x 1000 but I downscales this to 10 x 5 for the sake of readability.
0 means empty space.
S means starting point.
T means target point.
I created a function called cal_path to calculate the path between S and T. However the result is not correct. I've hard-coded an estimate answer. Any advice/help would be much appreciated.
Источник: https://stackoverflow.com/questions/498 ... like-array
I am working on a 2D string with \n new line at the end.
The maze is 1000 x 1000 but I downscales this to 10 x 5 for the sake of readability.
0 means empty space.
S means starting point.
T means target point.
I created a function called cal_path to calculate the path between S and T. However the result is not correct. I've hard-coded an estimate answer. Any advice/help would be much appreciated.
Источник: https://stackoverflow.com/questions/498 ... like-array
-
- Похожие темы
- Ответы
- Просмотры
- Последнее сообщение
-
-
Каков кратчайший путь к существующей папке плагинов с помощью file_get_contents()?
Anonymous » » в форуме Php - 0 Ответы
- 23 Просмотры
-
Последнее сообщение Anonymous
-