Unblock-Car Game Solver

版本 1.0.0.1 (4.8 KB) 作者: Bradley Knockel
Solves "Unblock Me" or "Sliding Cars" sort of puzzles
205.0 次下载
更新时间 2021/6/26

查看许可证

I have now converted this MATLAB code to C++ and Python to achieve much better performance! If you prefer C++ and Python, click the following link, and don't look back! I will no longer be updating the MATLAB version.
The most direct solution (fewest moves) can be searched for.
You can choose how "moves" are defined/counted.
To use, enter level information into puzzle.m, then run puzzle.m.
When a solution is found, a quick animation then a user-controlled mode help you view the solution (in addition to the solution being output to the Command Window).

引用格式

Bradley Knockel (2024). Unblock-Car Game Solver (https://www.mathworks.com/matlabcentral/fileexchange/63368-unblock-car-game-solver), MATLAB Central File Exchange. 检索来源 .

MATLAB 版本兼容性
创建方式 R2017a
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Strategy & Logic 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
版本 已发布 发行说明
1.0.0.1

added a link to my C++ and Python code

1.0.0.0

Fixed a subtle bug that prevented the code from finding a completely optimal solution when "moves" are defined such that "sequential moves of the same car collectively count as 1 move".
Made some comments more clear
The code can now automatically search for an optimal solution without guidance from the user.