Skip to content

Instantly share code, notes, and snippets.

@barneycarroll barneycarroll/posit.js
Last active Aug 29, 2015

Embed
What would you like to do?
Returning positive or negative of given number based on boolean.
function posit( x, positivity ){
return x * ( positivity * 2 - 1 );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.