Number.prototype.toBoolean ??=
function () {
    return this ? true : false;
}

Number.prototype.roundToDecimal ??= function(decimalPlaces:number){
    let factor = Math.pow(10,decimalPlaces);
    return Math.round(this * factor) / factor;
}