Git Product home page Git Product logo

elixir_skynet's Introduction

Skynet Exercise

The Exercise

The Server

The exercise is to model Skynet and Terminators using Elixir. A user can spawn Terminators and then those Terminators go on living their metallic, human-killing lives. Each Terminator has a chance to reproduce and be killed by Sarah Connor at specific intervals.

  • Take advantage of Elixir's OTP features.
  • When the app starts there should be no Terminators.
  • There should be a function that when called spawns a Terminator.
    • While this terminator is alive, it has a chance to reproduce and be killed by Sarah Connor.
    • Every 5 seconds, each terminator has a 20% chance of reproducing, creating 1 new terminator.
      • Terminators can reproduce more than once. They're trying to take over the world, after all.
    • Every 10 seconds, each terminator has a 25% chance to be killed by Sarah Connor.
  • Each terminator should have a unique ID.
  • There should be a function to manually kill a Terminator given its ID.
  • There should be a function to get a list of all living Terminators.
  • You don't need to keep track of ancestry / heirarchy.
  • Expect this part to be run and manually tested in iex.

The API

Create API endpoints for the following actions. You can pick what API protocol to use, if any.

  • Spawn a terminator
  • Manually kill a terminator
  • List all living terminators

The Front-end

Create a web page for the following. You can pick what technology to use and you won't be judged for how the page looks, style-wise.

  • A clickable button that says "Create Terminator"
  • A list of all living terminators, updated in real-time
  • The ability to select a specific terminator in the list and "manually kill" it

elixir_skynet's People

Contributors

dependabot[bot] avatar jeffgrunewald avatar lisycat avatar tracehelms avatar

Stargazers

 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.