This is a
playground to test code. It runs a full
Node.js environment and already has all of
npm’s 400,000 packages pre-installed, including
round-floor-ceil with all
npm packages installed. Try it out:
This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.
Create mozilla's round10 ceil10 floor10
var round_floor_ceil = require('round-floor-ceil');
floor10 - round down to the tenth-number value
round_floor_ceil.floor10(1.77, -1); // returns 1.7
ceil10 - round up to the tenth-number value
round_floor_ceil.ceil10(1.77, -1); // returns 1.8
In lieu of a formal style guide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.