ElixirStudyGroup / assemble_the_minions

A playground for creating an army minions to do our bidding
2 stars 5 forks source link

Feature/operations #2

Closed knightstick closed 6 years ago

knightstick commented 8 years ago

Implements basic arithmetic (+, -, *, /) for the Minions.

For a while I had a special bonus extra case, where, if you divide by zero, the state is set as "banana", but, my fancy pants refactoring broke it, so, I took it out again.

DuBistKomisch commented 8 years ago

🍌

mfeckie commented 8 years ago

I'm very sad that status was not set to banana... like VERY sad. In fact now I know that it was there, I demand that it be there or I will 😢

knightstick commented 8 years ago

@mfeckie If you can come up with a nice &() style anonymous function that returns "banana" when you try to divide by 0, then I'm happy to update.

mfeckie commented 8 years ago

@knightstick Challenge accepted https://github.com/ElixirStudyGroup/assemble_the_minions/commit/4fc026ab1b8377d8673deaba1e352b5d57b5a72b