Git Product home page Git Product logo

bridge-and-torch-problem's Introduction

Bridge and Torch Problem

This project was completed for the Artificial Intelligence course of the Department of Computer Science of the Athens University of Economics and Business, during the Fall semester of 2020-2021.

The objective of this assignment was to write a program that implements an AI algorithm (BFS, DFS, A* etc), so that an optimal solution can be found for the Bridge and Torch problem. In this project the A* algorithm with closed set was implemented. Given a number of people that want to cross the bridge, the algorithm must find the optimal solution, meaning the minimum amount of time for all people to pass across.

Useful Reads

For a full overview it is highly suggested that you read:

  • Project Assignment, that contains all the details about the game rules and what exactly was requested.
  • Project Report, that contains all the details about the algorithm implementation and the analysis of the code.

Dependencies

Program Execution

  1. Clone repository

    git clone https://github.com/nevwalkalone/Bridge-and-Torch-Problem.git
    
  2. Change directory to src

    cd Bridge-and-Torch-Problem\src
  3. Compile Main.java

    javac Main.java
  4. Run Main

    java Main

When the program runs, the user is asked to give as an input:

  1. the number of family members that must cross the bridge
  2. the total time limit that must not be exceeded
  3. the amount of time that is required for each member to cross from one side to the other

Program then ends with a fully displayed path from initial to terminal state (with exact moves in each step) if a solution that does not surpass the time limit is found.

Collaborators

Contributions

If you want to contribute, you can always create a pull request or open an issue.

License

MIT

bridge-and-torch-problem's People

Contributors

nevwalkalone avatar

Watchers

 avatar  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.