Add office photos
Capgemini logo
Engaged Employer

Capgemini

Verified
3.7
based on 42k Reviews
Video summary
Proud winner of ABECA 2024 - AmbitionBox Employee Choice Awards
Filter interviews by
Software Developer
Fresher
Experienced
Skills
Clear (2)

10+ Capgemini Software Developer Interview Questions and Answers for Freshers

Updated 23 Nov 2024

Q1. Find the Duplicate Number Problem Statement

Given an integer array 'ARR' of size 'N' containing numbers from 0 to (N - 2). Each number appears at least once, and there is one number that appears twice. Your tas...read more

Ans.

Find the duplicate number in an array of integers from 0 to (N - 2).

  • Iterate through the array and keep track of the frequency of each number using a hashmap.

  • Return the number that has a frequency greater than 1 as it is the duplicate number.

View 1 answer
right arrow

Q2. Minimum Operations to Make Strings Equal

Given two strings A and B consisting of lowercase English letters, determine the minimum number of pre-processing moves required on string A to make it equal to string B...read more

Ans.

The minimum number of pre-processing moves required on string A to make it equal to string B using specified operations.

  • Iterate through both strings simultaneously and check for differences.

  • Count the number of differences that can be fixed using the specified operations.

  • Return the count as the minimum number of pre-processing moves required.

Add your answer
right arrow

Q3. Ways To Make Coin Change

Given an infinite supply of coins of varying denominations, determine the total number of ways to make change for a specified value using these coins. If it's not possible to make the c...read more

Ans.

The task is to find the total number of ways to make change for a specified value using given denominations.

  • Use dynamic programming to solve this problem efficiently.

  • Create a 2D array to store the number of ways to make change for each value using different denominations.

  • Iterate through the denominations and update the array based on the current denomination.

  • The final answer will be in the last cell of the 2D array.

Add your answer
right arrow

Q4. The Skyline Problem

Compute the skyline of given rectangular buildings in a 2D city, eliminating hidden lines and forming the outer contour of the silhouette when viewed from a distance. Each building is descri...read more

Ans.

Compute the skyline of given rectangular buildings in a 2D city, eliminating hidden lines and forming the outer contour of the silhouette when viewed from a distance.

  • Iterate through the buildings and create a list of critical points (x, y) where the height changes.

  • Sort the critical points based on x-coordinate and process them to form the skyline.

  • Merge consecutive horizontal segments of equal height into one to ensure no duplicates in the output.

Add your answer
right arrow
Discover Capgemini interview dos and don'ts from real experiences

Q5. Wildcard Pattern Matching Problem Statement

Implement a wildcard pattern matching algorithm to determine if a given wildcard pattern matches a text string completely.

The wildcard pattern may include the charac...read more

Ans.

Implement a wildcard pattern matching algorithm to determine if a given wildcard pattern matches a text string completely.

  • Create a recursive function to match the pattern with the text character by character.

  • Handle the cases for '?' and '*' characters in the pattern.

  • Keep track of the current positions in the pattern and text while matching.

  • Return 'True' if the pattern matches the text completely, otherwise return 'False'.

Add your answer
right arrow

Q6. Time to Burn Tree Problem

You are given a binary tree consisting of 'N' unique nodes and a start node where the burning will commence. The task is to calculate the time in minutes required to completely burn th...read more

Ans.

Calculate the time in minutes required to completely burn a binary tree starting from a given node.

  • Perform a depth-first search (DFS) to calculate the time taken to burn the entire tree.

  • Keep track of the time taken to burn each node and return the maximum time as the result.

  • Consider the edge cases where the tree is empty or only consists of the start node.

Add your answer
right arrow
Are these interview questions helpful?

Q7. Anagram Pairs Verification Problem

Your task is to determine if two given strings are anagrams of each other. Two strings are considered anagrams if you can rearrange the letters of one string to form the other...read more

Ans.

Determine if two strings are anagrams of each other by checking if they have the same characters in different order.

  • Create a frequency map of characters for both strings and compare them.

  • Sort both strings and check if they are equal.

  • Use a hash table to store character counts and compare the counts for both strings.

Add your answer
right arrow

Q8. Next Greater Number Problem Statement

Given a string S which represents a number, determine the smallest number strictly greater than the original number composed of the same digits. Each digit's frequency from...read more

Ans.

Given a number represented as a string, find the smallest number greater than the original with the same set of digits.

  • Iterate from right to left to find the first digit that can be swapped with a larger digit to make the number greater.

  • Swap this digit with the smallest digit to its right that is larger than it.

  • Sort the digits to the right of the swapped digit in ascending order to get the smallest number greater than the original.

  • If no such number exists, return -1.

  • Example: ...read more

Add your answer
right arrow
Share interview questions and help millions of jobseekers 🌟
man with laptop

Q9. Kth Largest Number Problem Statement

Design a data structure to handle a stream of numbers dynamically and efficiently find the kth largest number at any given moment.

Explanation:

You will be presented with a ...read more

Ans.

Design a data structure to handle a stream of numbers and efficiently find the kth largest number at any given moment.

  • Implement a data structure that can accept an infinite stream of numbers

  • Efficiently find the kth largest number at any given moment

  • Handle queries of type 1 to add numbers and type 2 to find the kth largest number

  • Maintain the pool of numbers and update it dynamically based on queries

Add your answer
right arrow

Q10. Circular Move Problem Statement

You have a robot currently positioned at the origin (0, 0) on a two-dimensional grid, facing the north direction. You are given a sequence of moves in the form of a string of len...read more

Ans.

Determine if a robot's movement path is circular on a 2D grid given a sequence of moves.

  • Create a set of directions to keep track of the robot's current direction (north, east, south, west).

  • Simulate the robot's movement based on the given sequence of moves (L - turn left, R - turn right, G - move forward).

  • Check if the robot returns to the starting position after completing the sequence of moves.

  • Example: For 'GLGLGLG', the robot moves in a circular path and returns to the start...read more

Add your answer
right arrow

Q11. 1)What is oops? 2)difference between method overloading and method overriding? 3)what is static?

Ans.

Answers to common questions asked in a software developer interview.

  • OOPs stands for Object-Oriented Programming which is a programming paradigm based on the concept of objects.

  • Method overloading is when multiple methods have the same name but different parameters, while method overriding is when a subclass provides its own implementation of a method that is already present in its parent class.

  • Static is a keyword used to create variables and methods that belong to a class rath...read more

View 2 more answers
right arrow

Q12. What are the important categaries of software?

Ans.

The important categories of software are system software, application software, and programming software.

  • System software: manages computer hardware and provides common services for other software. Examples: operating systems, device drivers, firmware.

  • Application software: performs specific tasks for end-users. Examples: word processors, web browsers, video games.

  • Programming software: provides tools for software developers to create, debug, and maintain software. Examples: com...read more

Add your answer
right arrow

Q13. Why do you use two mobile numbers

Ans.

To separate personal and professional calls, and to ensure availability and accessibility.

  • Separate personal and professional calls

  • Ensure availability and accessibility

  • Maintain work-life balance

  • Avoid mixing personal and work-related contacts

Add your answer
right arrow

Q14. 1. Introduce yourself 2. How to fetch 50% record from table using SQL query

Ans.

To fetch 50% records from a table using SQL query

  • Use the LIMIT clause to specify the number of records to return

  • Calculate 50% of the total records in the table to determine the limit value

  • Order the records in a specific way if needed before applying the LIMIT clause

Add your answer
right arrow

Q15. 4)what is java& feature of java?

Ans.

Java is a popular programming language known for its portability and security features.

  • Java is an object-oriented language

  • It is platform-independent and can run on any device with a JVM

  • Java has automatic memory management through garbage collection

  • It has strong security features such as sandboxing and encryption

  • Java has a vast library of pre-built classes and APIs

  • Examples of Java-based applications include Android apps, enterprise software, and web applications

Add your answer
right arrow

Q16. what is filter in java 8

Ans.

Filter in Java 8 is a method used to iterate through a collection and filter out elements based on a specified condition.

  • Filter is a method in the Stream interface in Java 8.

  • It takes a Predicate as an argument to specify the condition for filtering.

  • Example: List names = Arrays.asList("Alice", "Bob", "Charlie"); List filteredNames = names.stream().filter(name -> name.startsWith("A")).collect(Collectors.toList());

Add your answer
right arrow

Q17. Java opps concept and implementation

Ans.

Java OOPs concepts refer to the principles of Object-Oriented Programming and their implementation in Java.

  • Java OOPs concepts include inheritance, encapsulation, polymorphism, and abstraction.

  • Inheritance allows a class to inherit properties and behavior from another class.

  • Encapsulation involves bundling data and methods that operate on the data into a single unit.

  • Polymorphism allows objects to be treated as instances of their parent class.

  • Abstraction involves hiding the imple...read more

Add your answer
right arrow
Contribute & help others!
Write a review
Write a review
Share interview
Share interview
Contribute salary
Contribute salary
Add office photos
Add office photos

Interview Process at Capgemini Software Developer for Freshers

based on 10 interviews
3 Interview rounds
Technical Round
Aptitude Test Round
Coding Test Round
View more
interview tips and stories logo
Interview Tips & Stories
Ace your next interview with expert advice and inspiring stories

Top Software Developer Interview Questions from Similar Companies

Adobe Logo
3.9
 • 67 Interview Questions
Cisco Logo
4.1
 • 50 Interview Questions
Visa Logo
3.5
 • 18 Interview Questions
NeoSOFT Logo
3.6
 • 14 Interview Questions
View all
Recently Viewed
INTERVIEWS
Alembic Pharmaceuticals
No Interviews
INTERVIEWS
Alembic Pharmaceuticals
No Interviews
INTERVIEWS
Alembic Pharmaceuticals
5.6k top interview questions
JOBS
QualityKiosk Technologies
No Jobs
INTERVIEWS
Alembic Pharmaceuticals
No Interviews
INTERVIEWS
Future Supply Chain Solutions
10 top interview questions
JOBS
QualityKiosk Technologies
No Jobs
JOBS
QualityKiosk Technologies
No Jobs
JOBS
QualityKiosk Technologies
No Jobs
JOBS
QualityKiosk Technologies
No Jobs
Share an Interview
Stay ahead in your career. Get AmbitionBox app
play-icon
play-icon
qr-code
Helping over 1 Crore job seekers every month in choosing their right fit company
75 Lakh+

Reviews

5 Lakh+

Interviews

4 Crore+

Salaries

1 Cr+

Users/Month

Contribute to help millions

Made with ❤️ in India. Trademarks belong to their respective owners. All rights reserved © 2024 Info Edge (India) Ltd.

Follow us
  • Youtube
  • Instagram
  • LinkedIn
  • Facebook
  • Twitter