X-Git-Url: http://git.scottworley.com/slidingtile/blobdiff_plain/0baac4a745fb164fe4daeee9b1f013e5affbde50..8e3c9cff3a9dbe44519dcea244d528809cc45821:/sliding_tile.cc diff --git a/sliding_tile.cc b/sliding_tile.cc index 572a6e3..2b7f31a 100644 --- a/sliding_tile.cc +++ b/sliding_tile.cc @@ -1,9 +1,13 @@ #include "sliding_tile_lib.h" #include "gflags/gflags.h" +#include + DEFINE_string(start, "", "The starting tile positions. 0 is the hole."); DEFINE_string(goal, "1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,0", "The desired tile positions. 0 is the hole."); +DEFINE_int32(max_frontier, 100000, "The maximum frontier size. Larger values run longer and give shorter paths."); int main(int argc, char** argv) { gflags::ParseCommandLineFlags(&argc, &argv, false); + std::cout << *find_path(FLAGS_start, FLAGS_goal, FLAGS_max_frontier); }