## Skill Subsist Impulse Ltd Interview Question for Software Engineer / Developers

• 0

Country: India
Interview Type: Written Test

Comment hidden because of low score. Click to expand.
1
of 1 vote

``````int heaviest(int a, int b, int c, int d){

if(a + b > c + d){
// heavier is either a or b
if (a - c > 0){
return a;
}
return b;
}
else {
// heavier is either c or d
if (c - a > 0){
return c;
}
return d;
}

}``````

Comment hidden because of low score. Click to expand.
1
of 1 vote

``````int heaviest(int a, int b, int c, int d){

if(a + b > c + d){
// heavier is either a or b
if (a - c > 0){
return a;
}
return b;
}
else {
// heavier is either c or d
if (c - a > 0){
return c;
}
return d;
}

}``````

Comment hidden because of low score. Click to expand.
0
of 0 vote

``````// ZoomBA
def find_largest_one(a,b,c,d){
s = a + b + c + d  // 3x + y
p1 = a + b // x + y or 2x
p2 = c + d // 2x or x + y
d = #| p1 - p2 | // absolute : y - x
x = (s - d)/4
y = x + d
}``````

Comment hidden because of low score. Click to expand.
0
of 0 vote

>

int heaviest(int a, int b, int c, int d){

if(a + b > c + d){
// heavier is either a or b
if (a - c > 0){
return a;
}
return b;
}
else {
// heavier is either c or d
if (c - a > 0){
return c;
}
return d;
}

}

Name:

Writing Code? Surround your code with {{{ and }}} to preserve whitespace.

### Books

is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.

### Videos

CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.