View Source FuelCalculator (FuelCalculator v0.1.0)

Documentation for FuelCalculator.

Link to this section Summary

Link to this section Functions

Specs

calculate(integer(), [tuple()]) :: integer() | String.t()

Calculate/2

used to calculate fuel required for a round trip ## Examples iex> FuelCalculator.calculate(28801, [{:launch, 9.807}, {:land, 1.62}, {:launch, 1.62}, {:land, 9.807}]) 51898

Link to this function

calculate(mass, mode, gravity)

View Source

Specs

calculate(integer(), atom(), integer()) :: integer() | String.t()

Calculate/3

used to calculate fuel required to perform single step, i.e land or launch ## Examples iex> FuelCalculator.calculate(28801, :land, 9.807) 13447 iex> FuelCalculator.calculate(28801, :land, :earth) 13447

Specs

help() :: String.t()

Help/1

## Examples iex> FuelCalculator.help