# Capgemini Previous Year Questions

19 November 2022

Capgemini Previous Year Questions

Check below videos for previous year questions:

Pseudocode Sample Questions:

Game based Aptitude Questions:

Capgemini Aptitude Questions

Q1) Three partners invested capital in the ratio 2 : 7 : 9. The time period for which each of them invested was in a ratio of the reciprocals of the amount invested.Find the share of the partner who bought in the highest capital, if profit is Rs.1080.

A. Rs.540

B. Rs.720

C. Rs.360

D. Rs.420
Answer : Option C

Q2) The values of x and y that simultaneously satisfy the equations 2x + 3y = 5 and 7x - 4y = 3 are

A. 1,1

B. 0,1

C. -1,1

D. 1,0
Answer : Option A

Q3) The teacher asked a student to perform 24 x 35. The student by mistake, performed 34 x 25 the difference between the correct answer and the answer obtained by the student is

A. 1296

B. 1424

C. 1016

D. 1632
Answer : Option A

Q4) Three pipes A, B and C can fill a cistern in 15, 20 and 30 min respectively. They were all turned on at the same time. After 5 minutes the first two pipes were turned off. In what time will the cistern be filled?

A. 5 minutes

B. 7.5 minutes

C. 13 minutes

D. 12.5 minutes
Answer : Option D

Q5) A is the father of B, B is the sister of C, D is the son of C, and E is the daughter of C. How is A related to D?

A. Granduncle

B. Grandfather

C. Uncle

D. Grandmother
Answer : Option B

Capgemini Pseudo code Questions

Q1) What is the output of this C code?

#include <stdio.h>

int main()

{

int i= 0, j = 0;

while (I1: i < 2)

{

i++;

while (j < 3)

{

printf("loop\n");

goto I1;

}

}

}

A. loop loop loop loop

B. loop loop

C. Compile time error

D. Infinite loop
Answer : Option C

Q2) What is the complexity of Krushal's algorithm for a complete graph of n vertices to the final minimum cost spanning tree? (if we use min-heap data structure)

A. Θ(n)

B. Θ(n logn)

C. Θ(n2)

D. Θ(n logn2)
Answer : Option D

Q3)
#include<stdio.h>
int main()
{
static int i = 5;
if (--i){
printf("%d ",i);
main();
}
}

A. 4 3 2 1

B. 4 4 4 4

C. 0 0 0 0

D. 1 2 3 4
Answer : Option A

Q4)

Consider the below given fragment of code.

int f(int &x, int c) {

c = c - 1;

if (c == 0) retum 1;

x = x + 1;

return f(x, c) * x;

}

In above program the first parameter is passed by reference and the second parameter is passed by value. If the value of p = 5 before the call then what is the value that returned by f(p, p)?

A. 6561

B. 161051

C. 55440

D. 3024
Answer : Option A

Q5)

Comment on the output of this C code?

#include <stdio.h>

int main()

{

int x = 3,i=0;

do{

X= x ++;

i++;

} while (i != 3);

printf(“%d\n", x);

}

A. Output will be 5

B. Output will be 6

C. Output will be 3

D. Undefined behaviour
Answer : Option C

Capgemini Pattern and Syllabus

Capgemini Frequently Asked Questions

Related Articles