Message on Whatsapp 8879355057 for DSA(OA + Interview) + Fullstack Dev Training + 1-1 Personalized Mentoring to get 10+LPA Job
0 like 0 dislike
630 views
in Online Assessments by Expert (46,090 points) | 630 views

1 Answer

0 like 0 dislike

First round was Machine coding

 

We had to make something Gmail

 

Second Round was UI tech

 

I was asked to make a alert with a backdrop

 

Third round Problem solving

 

{
	a : {
		b : (a,b,c)=>a+b+c,
		c : (a,b,c) => a+b-c,
		},
		d : (a,b,c) => a-b-c
}

Create a function
Fn(obj)(1,1,1);
output
{
	a : {
		b : 3,
		c : 1
		}
		d: -1
},


2. Implement LRU Cache in JS 
3. return the missing number from 2 arrays 
by Expert (46,090 points)
0 0
const Fn = (x) => (...args) => {
    for (let key in x) {
        let val = x[key];
        if (typeof val === 'function') {
            x[key] = val(...args);
        }
        else {
            x[key] = Fn(val)(...args);
        }
    }
    return x;
};

let test = {
    a: {
        b: (a, b, c) => a + b + c,
        c: (a, b, c) => a + b - c,
    },
    d: (a, b, c) => a - b - c
};

console.log(Fn(test)(1, 1, 1));