nygymankussainov / lem_in

Lem in

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Lem_in

This project is about finding the quickest way to get ants from start-room to end-room. Quickest way means the solution with the least number of lines, respecting the rules below.

Rules

  • All found paths must be disjoint.
  • At the beginning all ants are in start-room.
  • Each room can only contain one ant at a time. (expet start-room and end-room)
  • Ants have to avoid traffic jams as well as walking all over their fellow ants.
  • At each turn each ant can be moved only once and the room at the receiving end must be empty.

Usage

make
./lem-in < <input_file>

You can find input files in maps folder.

Run with visualisation

install sdl libraries for visualisation:

brew install SDL2 && brew install SDL2_ttf && brew install SDL2_image && brew install SDL2_gfx && brew install SDL2_mixer

compile:

make && make viz

run:

./lem-in < <input_file> | ./visual

Visualisation has done by Vlad Portnov

About

Lem in


Languages

Language:C 97.3%Language:C++ 1.8%Language:Objective-C 0.5%Language:Makefile 0.2%Language:Python 0.2%Language:CMake 0.0%Language:Shell 0.0%