For this Question: Create a class <code>FooBar</code>, whose objects have <code>foo</code> and <code>bar</code> as their attributes.
Also, write the function <code>solve(obj, param1, param2)</code>. 
<code>obj:</code> Object of class FooBar
<code>param1, param2:</code> some random numbers provided to you directly as input.

See the example for more clarity.Input will have <code>4</code> numbers, viz. <code>foo</code>,<code>bar</code>,<code>param1</code>, <code>param2</code> separated by spaces.

You need not worry about the same, it is handled properly by the hidden pre-function code.

Example:
4 5 6 7Function <code>solve(obj, param1, param2)</code> should return the value <code>obj.foo + obj.bar + func(param1, param2)</code>

There is a global function named <code>func(a, b)</code>, which takes two numbers as parameters, and its implementation is hidden.

<b>Note</b>: <code>func</code> uses properties of obj (using <code>this</code>, just like class methods), but does not accept obj as a parameter.const obj = new FooBar(1, 2); // say
console.log(solve(obj, param1, param2)) // prints a number as answer
// param1 and param2 are some hidden numbers passed as input.
, I have written this Solution Code: class FooBar {
    constructor(foo, bar) {
        this.foo = foo;
        this.bar = bar;
    }
}

function solve(obj, gfoo, gbar) {
    const g = func.bind(obj);
    return obj.foo + obj.bar + g(gfoo, gbar);
}
, In this Programming Language: JavaScript, Now tell me if this Code is compilable or not?