Skip to content

Repository files navigation

4Connect Solver

Build the Solver

Compile the C++ solver with:

make

Run the API Server

Start the server locally:

./run.sh

The server will be available at http://localhost:8080.

Get Next Move

Example Request:

{
    "board": [
        [0, 0, 0, 0, 0, 0, 0],
        [0, 0, 0, 0, 0, 0, 0],
        [0, 0, 0, 0, 0, 0, 0],
        [0, 0, 0, 0, 0, 0, 0],
        [0, 0, 0, 0, 2, 0, 0],
        [0, 0, 0, 1, 1, 2, 0]
    ],
    "current_player": 1,
    "valid_moves": [0, 1, 2, 3, 4, 5, 6]
}

Expose API Publicly

ngrok http 8080

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages