function F(x) { x = new Number(x); x.plus = function(y) { return F(x + y); }; x.minus = function(y) { return F(x - y) }; return x; } alert(F(10).plus(5).minus(3));