Gaussian/banker's rounding in JavaScript
The task is to implement the Gaussian/banker's rounding with the help of JavaScript. Here, few approaches are discussed. Approach 1: Get the d value(which tells the digits to which we need to round off). Calculate the m(pow(10, d)). Then shift the decimal after the digits we want to round off(if d=2