CommandAndService
TODO: Add description
Installation
If available in Hex, the package can be installed
by adding command_and_service
to your list of dependencies in mix.exs
:
def deps do
[
{:command_and_service, "~> 0.1.0"}
]
end
Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/command_and_service.
to calculate the path for a specific route
path = [{:launch, 9.807}, {:land, 1.62}, {:launch, 1.62}, {:land, 9.807}]
CommandAndService.calculate_fuel_for_path(28801, path) # 51898
to run the program as executable please run
./command_and_service calculate_fuel 28801 "[[:launch, 9.807], [:land, 1.62], [:launch, 1.62], [:land, 9.807]]"