i
SAP
Proud winner of ABECA 2024 - AmbitionBox Employee Choice Awards
Filter interviews by
Clear (1)
I was interviewed before May 2021.
Round duration - 90 minutes
Round difficulty - Medium
Given 'N' students standing in a row with specific heights, your task is to find the length of the longest strictly increasing subsequence of their heights...
Find the length of the longest strictly increasing subsequence of heights of students in a row.
Iterate through the heights array and for each element, find the length of the longest increasing subsequence ending at that element.
Use dynamic programming to keep track of the longest increasing subsequence length for each element.
Return the maximum length found as the result.
You are given the start and end times of 'N' intervals. Write a function to determine if any two intervals overlap.
If an interval ends at time T and anothe...
Given start and end times of intervals, determine if any two intervals overlap.
Iterate through intervals and check if any two intervals overlap by comparing their start and end times
Sort intervals based on start times for efficient comparison
Consider edge cases where intervals end and start at the same time
Various SQL queries related to data manipulation and retrieval were asked during the interview.
Basic SELECT queries to retrieve data from a single table
JOIN queries to retrieve data from multiple tables based on a common column
Aggregate functions like COUNT, SUM, AVG, etc. to perform calculations on data
Subqueries to retrieve data based on the result of another query
UPDATE queries to modify existing data in a table
DELE...
Round duration - 60 Minutes
Round difficulty - Medium
Given a string STR
of size N
and an integer M
representing the number of rows in the zig-zag pattern, return the string formed by concatenating all rows when the string ST...
Arrange a string in zig-zag pattern with given number of rows and concatenate the rows.
Iterate through the string and distribute characters to rows based on zig-zag pattern
Concatenate the characters in each row to get the final result
Handle edge cases like when number of rows is 1 or equal to the length of the string
You are given a permutation of 'N' integers. A sequence of 'N' integers is considered a permutation if it includes all integers from 1 to 'N' exactly once. Your task is ...
The task is to rearrange a given permutation of 'N' integers to form the lexicographically next greater permutation.
Iterate from right to left to find the first element that is smaller than the element to its right.
Swap this element with the smallest element to its right that is greater than it.
Reverse the elements to the right of the swapped element to get the lexicographically next greater permutation.
Round duration - 60 Minutes
Round difficulty - Medium
Given a string S, your task is to recursively remove all consecutive duplicate characters from the string.
String S
Output string
Recursively remove consecutive duplicate characters from a string.
Use recursion to check if the current character is the same as the next character, if so skip the next character
Base case: if the string is empty or has only one character, return the string
Example: Input: 'aaabcc', Output: 'abc'
Given an input string 'S', you are tasked with finding and returning all possible permutations of the input string.
The first and only line of input ...
Return all possible permutations of a given input string.
Use recursion to generate all possible permutations of the input string.
Swap characters at different positions to generate permutations.
Handle duplicate characters in the input string by using a set to store unique permutations.
Round duration - 60 Minutes
Round difficulty - Medium
Design an e-commerce website similar to Flipkart or Amazon.
Implement user-friendly interface for easy navigation
Include search functionality with filters for products
Incorporate secure payment gateway for transactions
Provide personalized recommendations based on user behavior
Include customer reviews and ratings for products
Implement order tracking and delivery status updates
Offer various payment options like credit/deb
Tip 1 : Prepare DSA well. Standard Leetcode-type questions will be asked.
Tip 2 : You should be crystal clear about your project/s as any question would be asked and you should be able to answer it.
Tip 3 : Prepare CS fundaments like OS, OOPs, DBMS, etc.
Tip 1 : Clearly mention the tech. stack you have worked on in the project/s
Tip 2 : As a fresher, you should add your coding profiles on CodeChef, Codeforces, etc. so as to make the resume shortlisting easy
I was interviewed before May 2021.
Round duration - 60 minutes
Round difficulty - Medium
Given a string STR and a non-empty string PTR, identify all the starting indices of anagrams of PTR within STR.
An anagram of a string is another string ...
Given a string STR and a non-empty string PTR, find all starting indices of anagrams of PTR within STR.
Create a frequency map of characters in PTR.
Use sliding window technique to check anagrams in STR.
Return the starting indices of anagrams found.
Given an array of integers, find the sum of all subsets in non-decreasing order of the given array.
N = 3, array = [1, 2]
[0, 1, 2, 3]
Find sum of all subsets in non-decreasing order of given array.
Use recursion to generate all subsets of the array
Calculate sum of each subset and store in a list
Sort the list in non-decreasing order to get the final result
Round duration - 60 minutes
Round difficulty - Medium
First he asked me to tell about myself, then he asked me some OOPS Concepts,difference in shallow copy and deep copy,
asked me to write a code for boundary traversal of binary tree.
Given a binary tree consisting of integers, your task is to provide the boundary nodes of this tree in an anti-clockwise direction, starting with the ro...
Boundary traversal of a binary tree to find left boundary, right boundary, and leaf nodes in an anti-clockwise direction.
Perform a pre-order traversal to get the left boundary nodes
Perform an in-order traversal to get the leaf nodes
Perform a post-order traversal to get the right boundary nodes
Combine the results to get the boundary nodes in anti-clockwise direction
Round duration - 60 minutes
Round difficulty - Easy
The second tech interview lasted for about an hour and half. First he asked me to tell about myself. Then he asked me how my first interview was. He then asked me where should I start, data structures, databases, to which I replied anywhere.
He started asking questions about C. He asked difference between call by pointer and call by reference. Whether a function can be defined as
void function(int &x, int &y);
Then he asked what is volatile data type in C. Then about the static data class.
He also asked me to write a program to find length of a string.
Then he asked about how functions in C work. How does the program know where to go back after a function is over, etc.
He then asked me if I knew C++, I said no. So he continued to ask a few questions on data structures.
He then asked about the ACID properties which a good database must have. He asked how are transactions managed by a database, what are commits, how, in case of a power failure, data is reverted back, etc.
Then he asked me whether I like to work individually or in a team. I said in a team. He then gave me scenario where I have to decide between a project I am working on, whose deadline is approaching, and helping a friend working on another project whose deadline is also approaching, and asked me what would I do in such a case.
This problem requires you to return a pointer that references the middle node of a singly linked list.
If the number of elements in the linked list is odd, ...
Return the middle node of a singly linked list, considering odd and even number of elements.
Traverse the linked list with two pointers, one moving twice as fast as the other
When the fast pointer reaches the end, the slow pointer will be at the middle
Return the node pointed to by the slow pointer as the middle node
Tip 1 : Practice at least 5 codes daily.
Tip 2 : Do at-least one machine Learning Project.
Tip 1 : Have at least three project.
Tip 2 : Put some achievements.
I was interviewed in Oct 2016.
Inheritance is a concept in object-oriented programming where a class inherits properties and behaviors from another class.
Inheritance allows for code reuse and promotes modularity.
The class that is being inherited from is called the superclass or base class.
The class that inherits from the superclass is called the subclass or derived class.
The subclass can access the public and protected members of the superclass.
Inhe...
Regular expressions in PHP are powerful tools for pattern matching and manipulating strings.
Regular expressions are defined using the preg_match() function in PHP.
They are used to search, replace, and validate strings based on specific patterns.
Regex patterns consist of a combination of characters and special symbols.
Modifiers can be added to the pattern to control the matching behavior.
Common regex functions in PHP in...
Polymorphism is the ability of an object to take on many forms. It allows objects of different classes to be treated as the same type.
Polymorphism allows a single interface to be used for different types of objects.
It enables code reusability and flexibility in object-oriented programming.
For example, a parent class 'Animal' can have multiple child classes like 'Dog', 'Cat', and 'Bird'. They can all be treated as 'Anim...
What people are saying about SAP
I was interviewed in Dec 2016.
Sort the individual digits of a 10 digit number.
Convert the number to a string to access individual digits
Use a sorting algorithm to sort the digits
Convert the sorted digits back to a number
The code for finding the Lowest Common Ancestor (LCA) in a Binary Search Tree (BST).
Start from the root node and compare it with the given two nodes.
If both nodes are smaller than the current node, move to the left subtree.
If both nodes are greater than the current node, move to the right subtree.
If one node is smaller and the other is greater, then the current node is the LCA.
Continue this process until the LCA is fou
A DBMS for managing college faculty, professors, courses, and students.
The DBMS should have tables for faculty, professors, courses, and students.
Each table should have appropriate attributes to store relevant information.
Relationships can be established between tables using foreign keys.
Queries can be used to retrieve information about faculty, professors, courses, and students.
The DBMS can be used to track enrollment
I was actively involved in coding competitions, hackathons, and programming clubs during college.
Participated in coding competitions such as ACM ICPC and Codeforces
Attended hackathons to work on real-world projects and improve problem-solving skills
Joined programming clubs to collaborate with peers and learn new technologies
Yes, I believe in seeking help when stuck in a problem as it leads to faster resolution and learning.
I believe in collaborating with team members to brainstorm solutions
I am not afraid to ask for help from more experienced developers
I utilize online resources like Stack Overflow or documentation when needed
Teamwork is collaborating with others towards a common goal, utilizing each member's strengths and skills.
Collaborating with others towards a common goal
Utilizing each member's strengths and skills
Communicating effectively and openly
Respecting and valuing diverse perspectives
Sharing responsibilities and supporting each other
Celebrating successes as a team
When faced with an unsolvable problem, I break it down, research, seek help, experiment, and iterate until a solution is found.
Break down the problem into smaller, manageable parts
Research and gather information related to the problem
Seek help from colleagues, online communities, or experts
Experiment with different approaches or solutions
Iterate and refine the solution based on feedback and results
In 5 years, I see myself as a senior software developer leading a team of developers on innovative projects.
Leading a team of developers on innovative projects
Senior software developer role
Continuing to learn and grow in the field
SAP interview questions for designations
Get interview-ready with Top SAP Interview Questions
I applied via Referral
Find the minimum and maximum values in an array in a single traversal.
Initialize min and max variables with the first element of the array
Iterate through the array and update min and max if a smaller or larger value is found
Return the min and max values
The maximum number of squares on a chessboard is 64.
The chessboard has 64 squares in total.
The number of squares on a chessboard can be calculated using the formula n^2, where n is the number of rows or columns.
In this case, n = 8 (8 rows and 8 columns), so the maximum number of squares is 8^2 = 64.
C++ is a programming language. Deep copy creates a new object and copies all values, while shallow copy creates a reference to the original object.
C++ is a general-purpose programming language
Deep copy creates a new object with its own copy of the data
Shallow copy creates a reference to the original object
Deep copy is safer but can be slower and consume more memory
Shallow copy is faster but can lead to unexpected behav
Pre initialization refers to the process of initializing variables or objects before they are used in a program.
Pre initialization helps avoid errors or unexpected behavior caused by using uninitialized variables.
It is a good practice to pre initialize variables with default values.
Pre initialization can be done using constructors, default values, or initialization blocks.
Example: int count = 0; initializes the variabl
Reverse a linked list with and without using Recursion
Iterative approach: Use three pointers to reverse the links between nodes
Recursive approach: Recursively reverse the rest of the list and then fix the links
Polymorphism refers to the ability of an object to take on many forms. The diamond problem occurs in multiple inheritance.
Polymorphism can be achieved through method overloading and method overriding.
Method overloading allows multiple methods with the same name but different parameters.
Method overriding occurs when a subclass provides a specific implementation of a method already defined in its superclass.
The diamond p...
The program should differentiate between integers and characters when using the assignment operator (=).
Check the data type of the variable before assigning a value.
Use conditional statements to perform different actions based on the data type.
For integers, assign the value directly. For characters, convert the character to its ASCII value and assign it.
Sort an array by moving all zeroes to the end.
Iterate through the array and move all non-zero elements to the front.
Count the number of zeroes encountered and append them at the end of the array.
Use two pointers to swap elements and maintain the order.
The number of VTables created in a class hierarchy depends on the number of virtual functions and the number of derived classes.
VTables are used in object-oriented programming languages to implement dynamic dispatch.
Each class with at least one virtual function has its own VTable.
Derived classes inherit the VTable of their base class and add their own entries for any additional virtual functions.
The total number of VTa...
List is preferred when frequent insertion and deletion is required. Vector is preferred when random access is required.
List is implemented as a doubly-linked list, allowing for efficient insertion and deletion at any position.
Vector is implemented as a dynamic array, allowing for efficient random access.
Use List when the number of elements is expected to change frequently and the order of elements matters less.
Use Vect...
The given string needs to be reversed and the words need to be rearranged.
Split the string into an array of words
Reverse the array
Join the array elements with a space in between
Design a parking lot with Logic Flow Diagram, E-R diagram, DB tables with relations, and commands for transactions.
Identify the types of vehicles that will use the parking lot
Determine the number of parking spaces needed for each vehicle type
Create a flow diagram to show the process of entering and exiting the parking lot
Design an E-R diagram to show the relationships between entities such as vehicles, parking spaces, ...
To find min and max of an array in one traversal, initialize min and max to first element and compare with rest.
Initialize min and max to first element of array
Traverse the array and compare each element with min and max
Update min and max accordingly
Return min and max
Given a chessboard, find the maximum number of squares present.
Start with the smallest square and count all possible squares
Use the formula n*(n+1)*(2n+1)/6 to find the total number of squares in an n x n chessboard
Add up the squares of all sizes from 1 to n to get the maximum number of squares
For example, an 8 x 8 chessboard has 204 squares
C++ is a high-level programming language used for developing system software, application software, device drivers, and video games.
C++ was developed by Bjarne Stroustrup in 1983.
It is an extension of the C programming language.
C++ supports object-oriented programming, generic programming, and low-level memory manipulation.
It is used in developing operating systems, browsers, databases, and more.
Examples of popular sof...
Deep copy creates a new object with a new memory address, while shallow copy creates a new reference to the same memory address.
Deep copy duplicates the object and all its nested objects, while shallow copy only duplicates the top-level object.
Deep copy is slower and more memory-intensive than shallow copy.
Shallow copy can lead to unexpected behavior if the original object is modified.
In Python, deep copy can be achiev...
Preinitialization is the process of initializing data or objects before they are actually needed.
Preinitialization can improve performance by reducing the time needed to initialize data or objects when they are actually needed.
It can also help to avoid delays or interruptions during runtime.
Examples of preinitialization include preloading data into memory, initializing objects in advance, and caching frequently used da
Polymorphism can be achieved through method overloading, method overriding, and interfaces. Multiple inheritance can be solved using interfaces.
Method overloading allows multiple methods with the same name but different parameters
Method overriding allows a subclass to provide its own implementation of a method already defined in its superclass
Interfaces provide a way to achieve multiple inheritance by allowing a class ...
WAP to generate a matrix from a given tree.
Create a 2D array to store the matrix
Traverse the tree and fill the matrix accordingly
Use BFS or DFS to traverse the tree
The matrix will be symmetric along the diagonal
Primary key is a column or set of columns that uniquely identifies each row in a table. Unique key is a constraint that ensures uniqueness of values in a column or set of columns.
Primary key is used to enforce data integrity and ensure that each row in a table can be uniquely identified.
Unique key is used to ensure that no two rows in a table have the same values in a column or set of columns.
Primary key can be a singl...
Yes, a unique key can be a primary key.
A primary key is a unique identifier for a record in a table.
A unique key is a constraint that ensures the values in a column are unique.
A unique key can be used as a primary key if it meets the requirements.
A primary key cannot have NULL values, while a unique key can have one NULL value.
Foreign key is a column in a table that refers to the primary key of another table.
It establishes a relationship between two tables.
It ensures referential integrity.
It can be null, but only if it is defined as nullable.
It helps in joining tables.
Example: Customer table has a foreign key to the Order table's primary key.
Example: Order table's foreign key can be null if the order has not been placed by any customer yet.
Normalization is the process of organizing data in a database to reduce redundancy and improve data integrity.
Normalization involves breaking down a database into smaller, more manageable tables.
It helps to eliminate data redundancy and inconsistencies.
Normalization ensures that each table has a primary key and that data is stored in a logical and consistent manner.
It improves data integrity and reduces the likelihood ...
Normalized form is better for data consistency and scalability.
Normalized form reduces data redundancy and ensures data consistency.
Normalized form allows for easier scalability and maintenance.
Single table/2 tables may be appropriate for small, simple datasets.
Normalized form may require more complex queries to retrieve data.
Normalized form may require more storage space due to additional tables.
Example: Normalized fo...
Create a database for Indian Premier League (IPL)
Identify entities like teams, players, matches, venues, etc.
Create tables for each entity with relevant attributes
Establish relationships between tables using foreign keys
Add constraints like unique, not null, default values, etc.
Populate tables with data from reliable sources
Query to find player with maximum runs in a match on given date and venue
Use MAX() function to find maximum runs
Join tables for player name, match details and runs scored
Filter by given date and venue
Order by runs scored and limit to 1 result
I was interviewed before Jun 2016.
I am a passionate software developer with experience in Java, Python, and web development.
Experienced in Java, Python, and web development technologies
Strong problem-solving skills
Excellent team player with good communication skills
SAP is a leading software provider with a wide range of products and solutions for businesses.
SAP offers a comprehensive suite of enterprise software solutions for various industries.
Their products are known for their scalability, reliability, and integration capabilities.
SAP has a strong global presence and a large customer base, including many Fortune 500 companies.
Their software helps businesses streamline processes...
SAP is a multinational software corporation that provides enterprise software solutions.
SAP develops and sells software for managing business operations and customer relations.
Their software helps organizations streamline processes, improve efficiency, and make data-driven decisions.
SAP offers a wide range of products, including ERP (Enterprise Resource Planning), CRM (Customer Relationship Management), and SCM (Supply...
I have worked on various projects including a web application for inventory management and a mobile app for task tracking.
Developed a web application using React for inventory management
Created a mobile app using Flutter for task tracking
Implemented RESTful APIs for communication between frontend and backend
Utilized databases like MySQL and MongoDB for data storage
Some of the top questions asked at the SAP Software Developer interview -
The duration of SAP Software Developer interview process can vary, but typically it takes about less than 2 weeks to complete.
based on 24 interviews
5 Interview rounds
based on 180 reviews
Rating in categories
Software Developer
1k
salaries
| ₹0 L/yr - ₹0 L/yr |
Developer
865
salaries
| ₹0 L/yr - ₹0 L/yr |
Developer Associate
826
salaries
| ₹0 L/yr - ₹0 L/yr |
Senior Developer
497
salaries
| ₹0 L/yr - ₹0 L/yr |
Business Process Consultant
422
salaries
| ₹0 L/yr - ₹0 L/yr |
Oracle
SAS
Zoho
IBM