Skip to content

Simulate elevators service, given a number of floors X elevators.

Notifications You must be signed in to change notification settings

jotafeldmann/elevators

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

elevators CI

Simulate elevator's service, given a number of floors X elevators.

Try it online:

Motivation

We use elevators everyday. But everytime I think "all this elevator's behaviours can be improved, somehow".
So, as a programmer, I'm thinking how to describe this challenge in a generic model, just for fun.

Purpose

  • Simulate elevator's service, given a number of floors X elevators
  • Learn Deno

How to use

git clone https://github.com/jotafeldmann/elevators
  • Install
make install
  • Test
make test
  • Default/dev (dev mode, watch changes and reload)
make

#or

make dev
  • Run (prod env)
make run

Preview

Preview

Deno styleguide

Testing

Roadmap

  • TypeScript setup
  • Request elevator at floors
  • Add watch changes and reload task
  • Add event controller
  • Add basic visual interface
  • Add continuous flow of requests
  • Converted to Deno
  • Add make tests to basic classes
  • Add make fmt
  • Add CI (Github Actions)
  • Add CLI/dynamic parameters (number of floors, elevators, speed)
  • Add metrics (e.g. waiting time, movements)
  • Add simulation cases results
  • Request floors from elevators (building.requestElevatorAtFloor().then(e => e.requestFloor(5)))
  • Limit and control number of people inside elevators
  • Add different rules for elevators (e.g. elevator 2 only receive requests from last floors)
  • Prediction (AI?) max efficiency

About

Simulate elevators service, given a number of floors X elevators.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published