GithubHelp home page GithubHelp logo

mazechallenge's Introduction

CookUnity - Take Home Test

Description

The test consists in solving the following maze:

    ["A", "B", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A"]
    ["A", "C", "A", "D", "D", "E", "A", "C", "C", "C", "D", "A"]
    ["A", "C", "C", "D", "A", "E", "A", "D", "A", "D", "A", "A"]
    ["A", "A", "A", "A", "A", "E", "D", "D", "A", "D", "E", "A"]
    ["A", "C", "C", "D", "D", "D", "A", "A", "A", "A", "E", "A"]
    ["A", "C", "A", "A", "A", "A", "A", "D", "D", "D", "E", "A"]
    ["A", "D", "D", "D", "E", "E", "A", "C", "A", "A", "A", "A"]
    ["A", "A", "A", "E", "A", "E", "A", "C", "C", "D", "D", "A"]
    ["A", "D", "E", "E", "A", "D", "A", "A", "A", "A", "A", "A"]
    ["A", "A", "D", "A", "A", "D", "A", "C", "D", "D", "A", "A"]
    ["A", "D", "D", "D", "A", "D", "C", "C", "A", "D", "E", "B"]
    ["A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A", "A"]

You have to start and finish the maze in the letter B the rules are very simple, you should solve it considering that you can only walk in the 3 letter and consecutive sequence CCC-DDD-EEE-DDD and repeating the pattern. The consecutive letters don’t need to be on the same line. Your solution should be able to find the exit starting on any of the maze entries. You can cut the sequence if you find the letter B. I will assume that B-CCC-DDD-E-B or B-CCC-DDD-CC-B can be possible solutions. The pattern to find is B-XXX-XXX-....-X*N-B, being Xs consecutive between them and 1<=N<=3

Installation

    npm install

Run

    npm run start

Lint

    npm run lint

Test

    npm run test

Test with coverage

    npx jest --coverage

mazechallenge's People

Contributors

alexanderarmua avatar

Watchers

James Cloos 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.