Code Monkey home page Code Monkey logo

labyrinth's Introduction

Labyrinth

This project is about implementing labyrinth with C using DFS (Depth-first search) and BFS (Breadth-first search) algorithms.

Screenshots

Maze generating

  • Generating a random maze rusing Depth-first search (DFS) algorithm

Maze generating

Maze solving

  • Solving the maze by finding the shortest path using Breadth-first search (BFS) algorithm

Maze sloving

SDL2 instalation

Linux instalation

  • Run the following commands: (for ubuntu)
    • sudo apt update (update packages list)
    • sudo apt install build-essential (install gcc and make)
    • apt-get install libsdl2-dev (install SDL2)
  • For other distributions, you can check this link

Windows instalation

  • Download and install msys2 from https://www.msys2.org/
  • Open start menu and open the msys2 terminal (MSYS2 MinGW 64-bit)
  • Run the following commands: (for 64 bit systems)
    • pacman -Syu (update the package database and base packages)
    • pacman -Su (update the rest of the base packages)
    • pacman -S --needed base-devel mingw-w64-x86_64-toolchain (install gcc and make)
    • pacman -S mingw-w64-x86_64-SDL2 (install SDL2)

Build the project

  • Open terminal and go to projet's directory (by typing cd project_diretory)
  • Run the command make
  • You can also build the project without using make by running the command line gcc src/*.c -o application `sdl2-config --cflags --libs`

labyrinth's People

Contributors

alami-oussama avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.